Linux/Ubuntu 18

From Omnia
Jump to navigation Jump to search

Missing rc.local

Not created by default, but can be added.

Make sure to create with:

#!/bin/bash

and

chmod +x /etc/rc.local

Check status:

systemctl status rc-local 

Run:

systemctl restart rc-local 

Ref

systemd

Systemd Unit Files Locations Directory - Description:

/usr/lib/systemd/system/
Systemd unit files distributed with installed RPM packages.
/run/systemd/system/
Systemd unit files created at run time. This directory takes precedence over the directory with installed service unit files.
/etc/systemd/system/
Systemd unit files created by systemctl enable as well as unit files added for extending a service. This directory takes precedence over the directory with runtime unit files.

10.6. Creating and Modifying systemd Unit Files - Red Hat Customer Portal - https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/system_administrators_guide/sect-managing_services_with_systemd-unit_files

/etc/systemd/system/

https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/system_administrators_guide/chap-Managing_Services_with_systemd#tabl-Managing_Services_with_systemd-Introduction-Units-Locations

5.0 Kernel

apt install linux-virtual-hwe-18.04

Note the --install-recommends just auto installs the suggested packages.

To install HWE kernel in Ubuntu desktop along with newer xorg, you can use this command in the terminal:

sudo apt install --install-recommends linux-generic-hwe-18.04 xserver-xorg-hwe-18.04

If you are using Ubuntu Server edition, you won’t have the xorg option. So just install the HWE kernel in Ubutnu server:

sudo apt-get install --install-recommends linux-generic-hwe-18.04


"For server versions and people who downloaded 18.04 and 18.04.1, you’ll have to install the HWE kernel. Once you do that, you’ll get the newer kernel releases provided by Ubuntu to the LTS version."

Ref:

VNC

apt-get install tightvncserver xterm xfce4 xfonts-base

? dbus-x11

netplan

/etc/netplan/01-netcfg.yaml
# This file describes the network interfaces available on your system
# For more information, see netplan(5).
network:
  version: 2
  renderer: networkd
  ethernets:
    ens18f0:
      dhcp4: no
      addresses: [10.0.0.2/24]
      gateway4: 10.0.0.1
    ens18f1:
      dhcp4: yes
sudo netplan apply
sudo netplan --debug apply

Ref: https://www.howtoforge.com/linux-basics-set-a-static-ip-on-ubuntu

ifupdown

/etc/network/interfaces:

# ifupdown has been replaced by netplan(5) on this system.  See
# /etc/netplan for current configuration.
# To re-enable ifupdown on this system, you can run:
#    sudo apt install ifupdown

auto ens18f0
iface ens18f0 inet static
    address 10.0.0.2
    netmask 255.255.255.0
    gateway 10.0.0.1

auto ens18f1
iface ens18f1 inet dhcp
apt install ifupdown

---

Error:

RTNETLINK answers: File exists
Failed to bring up eth0

Solution:

sudo ip addr flush dev

Remote Screen Sharing

Ubuntu Remote Desktop - 18.04 Bionic Beaver Linux - LinuxConfig.org https://linuxconfig.org/ubuntu-remote-desktop-18-04-bionic-beaver-linux

Settings -> Sharing -> Screen Sharing

--

First go to Settings and then “Sharing”. Make sure to turn the Slider in the upper right hand corner to the ON position.

Disable encryption:

Now you need to install dconf-editor with this command:

sudo apt-get install conf-editor

Now open a terminal and type

dconf-editor

Now navigate to:

ORG > GNOME > DESKTOP > REMOTE ACCESS

Then find the “Require Encryption” setting and toggle it off


ref: https://www.hagensieker.com/wordpress/2018/04/27/how-to-do-screen-sharing-on-ubuntu-18-04/

FTDI Driver

apt update
apt install linux-modules-extra-`uname -r`
# manually load driver or reboot
modprobe ftdi_sio
ls /dev/ttyUSB*

keywords