JCL

FEUP/DEI & INESC TEC

User Tools

Site Tools


doc:linux:ubuntu2204-jclell3

Ubuntu 22.04.2 LTS (Jammy Jellyfish)

janelas!

  • jclell3, jlopes@fe.up.pt, PIN standard, Não a tudo!
  • run "Dell optimizer" (bom para quem usa Janelas)
  • run "Dell Command | Update" (verificar atualizações)
    • etiqueta de serviço: DLC7MS3
    • 7 atualizações (nas janelas)
    • Updating firmware (Flash): BIOS, Intel ME FW, EC BIOS GUID, Intel TBT Retimer… BIOS UPDATE SUCCESFUL!
  • Turn off Windows BitLocker encryption DELETEME
    • Settings > type Manage BitLocker in the search box. Alternatively, open Control Panel > System and Security > BitLocker Drive Encryption.

1. Create a bootable USB stick

  1. Get an Ubuntu ISO file ✔
  2. Launch Startup Disk Creator ✔
  3. ISO and USB selection ✔
  4. Confirm USB device ✔
jlopes@jclell3:~Downloads/> CHKSHA256.sh b98dac940a82b110e6265ca78d1320f1f7103861e922aa1a54e4202686e9bbd3 ubuntu-22.04.2-desktop-amd64.iso 
Checking file: /home/jlopes/Downloads/ubuntu-22.04.2-desktop-amd64.iso
result hash: b98dac940a82b110e6265ca78d1320f1f7103861e922aa1a54e4202686e9bbd3
checksums OK.

2. fresh install

Things to know and check before you start an install

  • Unordered List ItemPress the <F2> key on start up to enter the BIOS setup screens.
  • Ensure that the BIOS is set to UEFI, and disable the secure boot, and disable the Legacy option ROMS.

Set up the Ubuntu Install

  1. Insert the Ubuntu disk into your DVD drive or connect your bootable USB into a port on the computer
  2. Tap rapidly on the <F12> key when the Dell logo appears during startup. This takes you to the Boot Once menu
  3. You can use the Cursor or Arrow keys to navigate the menu and select your choice. You can choose to either boot from USB or Boot from CD/DVD Drive. Once your choice is selected, press the ENTER key
  4. Install Ubuntu button. The install wizard should appear and prompt you through some choices.
  • wifi, vJCL7_5G
  • install third-party software for graphics …
  • erase disk and install Ubuntu
  • Lisbon
  • jclell3, jlopes/pass_#3
  • restart…
  • skip Ubuntu Pro
  • no location services
  • no installs for "Software"
  • Firefox with the account & Sync preferences

3. Post-install

3.1 Configure sudo

#sudo vi /etc/group #add jlopes to sudo group
sudo vi /etc/sudoers.d/jlopes
# jlopes
#
# To allow members of group sudo to not need a password
# override the normal entry 
%sudo ALL=NOPASSWD: ALL

3.2 Product name

sudo dmidecode | grep "Product Name"
	Product Name: Latitude 7340
	Product Name: 0C5RG2

3.3 Upgrade

sudo apt update && sudo apt upgrade

3.4 update firmware

jlopes@jclell3:~$ sudo fwupdmgr refresh
Updating lvfs
Downloading…             [***************************************]
Downloading…             [***************************************]
jlopes@jclell3:~$ sudo service fwupd status
● fwupd.service - Firmware update daemon
     Loaded: loaded (/lib/systemd/system/fwupd.service; static)
     Active: active (running) since Fri 2023-07-07 23:19:16 WEST; 3min 31s ago
       Docs: https://fwupd.org/
   Main PID: 3523 (fwupd)
      Tasks: 6 (limit: 37926)
     Memory: 59.8M
        CPU: 799ms
     CGroup: /system.slice/fwupd.service
             ├─3523 /usr/libexec/fwupd/fwupd
             └─3547 gpg-agent --homedir /var/lib/fwupd/gnupg --use-standard-socket --daemon
 
jul 07 23:19:14 jclell3 systemd[1]: Starting Firmware update daemon...
jul 07 23:19:16 jclell3 systemd[1]: Started Firmware update daemon.
jul 07 23:19:16 jclell3 fwupd[3523]: 22:19:16:0100 FuPluginPciMei       ME family not supported for 0:16.1.25.2128
jul 07 23:19:16 jclell3 fwupd[3523]: 22:19:16:0701 FuEngine             failed to get releases for UEFI dbx: No releases found: Not compatible with org.freedesktop.fwupd version 1.7.9, requires >= 1.9.1
jul 07 23:19:18 jclell3 fwupd[3523]: 22:19:18:0315 FuEngine             failed to get releases for UEFI dbx: No releases found: Not compatible with org.freedesktop.fwupd version 1.7.9, requires >= 1.9.1
jlopes@jclell3:~$ sudo fwupdmgr update
Devices with no available firmware updates: 
 • UEFI dbx
No updatable devices

ppa:somerville-dla-team

FIXME

sudo add-apt-repository ppa:somerville-dla-team/ppa

Ubuntu Pro

jlopes@jclell3:~> pro --version
28.1~22.04
jlopes@jclell3:~> # sudo apt install ubuntu-advantage-tools
jlopes@jclell3:~> pro security-status
2594 packages installed:
     1921 packages from Ubuntu Main/Restricted repository
     662 packages from Ubuntu Universe/Multiverse repository
     2 packages from third parties
     9 packages no longer available for download
 
To get more information about the packages, run
    pro security-status --help
for a list of available options.
 
This machine is receiving security patching for Ubuntu Main/Restricted
repository until 2027.
This machine is NOT attached to an Ubuntu Pro subscription.
 
Ubuntu Pro with 'esm-infra' enabled provides security updates for
Main/Restricted packages until 2032.
 
Ubuntu Pro with 'esm-apps' enabled provides security updates for
Universe/Multiverse packages until 2032. There are 35 pending security updates.
 
Try Ubuntu Pro with a free personal subscription on up to 5 machines.
Learn more at https://ubuntu.com/pro
jlopes@jclell3:~> pro security-status --esm-apps
2594 packages installed:
     662 packages from Ubuntu Universe/Multiverse repository
 
Ubuntu Pro with 'esm-apps' enabled provides security updates for
Universe/Multiverse packages until 2032. There are 35 pending security updates.
 
Run 'pro help esm-apps' to learn more
 
Installed packages with an available esm-apps update:
imagemagick imagemagick-6-common imagemagick-6.q16 jupyter-core libavcodec58
libavfilter7 libavformat58 libavutil56 libjs-jquery-ui libmagick++-6.q16-8
libmagickcore-6.q16-6 libmagickcore-6.q16-6-extra libmagickwand-6.q16-6
libopenexr25 libopusfile0 libpostproc55 libswresample3 libswscale5 libvlc-bin
libvlc5 libvlccore9 python3-jupyter-core vlc vlc-bin vlc-data vlc-l10n
vlc-plugin-access-extra vlc-plugin-base vlc-plugin-notify vlc-plugin-qt
vlc-plugin-samba vlc-plugin-skins2 vlc-plugin-video-output
vlc-plugin-video-splitter vlc-plugin-visualization
jlopes@jclell3:~> sudo pro attach C13NdhxB9ZsuxBCkxuSb6nW5TrWXfe # get YOUR_TOKEN from Ubuntu One account
Enabling default service esm-apps
Updating package lists
Ubuntu Pro: ESM Apps enabled
Enabling default service esm-infra
Updating package lists
Ubuntu Pro: ESM Infra enabled
Enabling default service livepatch
Installing canonical-livepatch snap
Canonical livepatch enabled.
Unable to determine current instance-id
This machine is now attached to 'Ubuntu Pro - free personal subscription'
 
SERVICE          ENTITLED  STATUS    DESCRIPTION
esm-apps         yes       enabled   Expanded Security Maintenance for Applications
esm-infra        yes       enabled   Expanded Security Maintenance for Infrastructure
livepatch        yes       warning   Current kernel is not supported
realtime-kernel* yes       disabled  Ubuntu kernel with PREEMPT_RT patches integrated
usg              yes       disabled  Security compliance and audit tools
[...]
    Account: jlopes@fe.up.pt
Subscription: Ubuntu Pro - free personal subscription
  • Open Applications > Software & Updates

Ubuntu Pro

3.5 SSH

sudo apt install openssh-server openssh-client
sudo vi /etc/ssh/sshd_config # change to "PasswordAuthentication no"
sudo service ssh restart
# recover public and private SSH keys
JCLELL2=192.168.1.59
rsync -avz jlopes@$JCLELL2/.ssh ~
# generate RSA key pair
ssh-keygen -t rsa -f /home/jlopes/.ssh/id_rsa_jclell3
Generating public/private rsa key pair.
Enter passphrase (empty for no passphrase): 
Enter same passphrase again: 
Your identification has been saved in /home/jlopes/.ssh/id_rsa_jclell3
Your public key has been saved in /home/jlopes/.ssh/id_rsa_jclell3.pub
The key fingerprint is:
SHA256:CvuJYlb8uVRDDJove3vHNdNnZRuXQyIMIhlFYi4MggM jlopes@jclell3
The key's randomart image is:
+---[RSA 3072]----+
|E.   =*+ .o      |
|+ o o+oo.  o . . |
| . oo.  o   . o .|
|    .. .       ++|
|   .o . S    . .*|
|    o= o .  + ..o|
|   .o.+. . . o o |
|  +  =oo. o      |
| o .. =o .       |
+----[SHA256]-----+
# Generate a new pair "ED25519" 256 (for git.fe.up.pt):
# ssh-keygen -o -a 100 -t ed25519 -f ~/.ssh/id_ed25519 -C "jlopes@fe.up.pt"
  • install keys
ln -s id_rsa_jclell3 id_rsa
ln -s id_rsa_jclell3.pub id_rsa.pub

# add key to authorized_keys of the remote machines
cat id_rsa_jclell2.pub >> authorized_keys

#chmod 600 authorized_keys

3.6 Sync with jclell2

# do this in the old machine

#alias for the new machine
JCLELL3=192.168.1.141

LOC=arc-data
rsync -avz $HOME/$LOC jlopes@$JCLELL3:~

sent 11.521.103.371 bytes  received 1.709.412 bytes  56.072.081,67 bytes/sec
total size is 14.349.567.980  speedup is 1,25

LOC=Qsync

sent 23.439.976.888 bytes  received 2.939.914 bytes  59.424.377,19 bytes/sec
total size is 29.705.239.565  speedup is 1,27

LOC=Desktop

sent 3.382.415.792 bytes  received 108.941 bytes  51.641.598,98 bytes/sec
total size is 6.056.926.513  speedup is 1,79

LOC=GitProjects

sent 752.055.886 bytes  received 2.019.064 bytes  23.938.887,30 bytes/sec
total size is 1.681.256.681  speedup is 2,23

LOC=Music

sent 12.041.055.649 bytes  received 48.109 bytes  83.910.130,72 bytes/sec
total size is 12.191.648.384  speedup is 1,01

LOC=NetBeansProjects

sent 246.835 bytes  received 11.300 bytes  172.090,00 bytes/sec
total size is 4.048.911  speedup is 15,69

LOC=Pictures

sent 4.782.942.962 bytes  received 19.187 bytes  84.654.197,33 bytes/sec
total size is 4.786.282.282  speedup is 1,00

LOC=Videos

sent 5.347.113.088 bytes  received 1.577 bytes  85.553.834,64 bytes/sec
total size is 6.151.325.863  speedup is 1,15

LOC=tmp

sent 10.712.934.918 bytes  received 551.164 bytes  80.856.498,73 bytes/sec
total size is 14.510.303.120  speedup is 1,35

#sync some others
for f in ".emacs .gnupg .java .jupyter .thunderbird .unison .zoom"; do rsync -avz $HOME/$f jlopes@$JCLELL3:~ ; done

#config bash
for f in ".bash_profile .bashrc .face .profile"; do   rsync -avz $HOME/$f jlopes@$JCLELL3:~ ; done

sent 12.171.960.833 bytes  received 47.929 bytes  77.282.595,31 bytes/sec
total size is 20.556.585.086  speedup is 1,69

# cups printer.conf & ppd/
rsync -avz /etc/cups jlopes@$JCLELL3:~/tmp

basrc bashprofile

3.7 network

Wifi: vJCL7_5G + vJCL7-2_5G

address: 192.168.1.55
netmask: 255.255.255.0
gateway: 192.168.1.1
nameserver: 192.168.1.1, 8.8.4.4
hostname: jclell3

Wifi: eduroam

Security: WAP2 Enterprise
Authentication: PEAP
Anonynous identity: anon@fe.up.pt
CA certificate: FEUP-ROOT-CA.pem -> None
PEAP version: version 1 -> Auto
Inner authentication: MSCHAPv2
User name: jlopes@fe.up.pt
password: ***********

wired@home

address: 192.168.1.59
netmask: 255.255.255.0
gateway: 192.168.1.1
nameserver: 192.168.1.1, 8.8.4.4
hostname: jclell3

wired@FEUP

Automatic (DHCP)
nameserver: 193.136.28.138,193.136.28.10,193.136.28.9
sudo apt install net-tools
ifconfig -a
...
inet 192.168.1.59  netmask 255.255.255.0  broadcast 192.168.1.255
ether ac:1a:3d:b7:5b:30  txqueuelen 1000  (Ethernet)
...
inet 192.168.1.55  netmask 255.255.255.0  broadcast 192.168.1.255
ether 64:49:7d:99:c7:da  txqueuelen 1000  (Ethernet)
...

VPN: FEUPNet

#VPN L2TP
sudo apt-get update
sudo apt-get install network-manager-l2tp
sudo apt-get install network-manager-l2tp-gnome
sudo service xl2tpd stop
sudo update-rc.d xl2tpd disable

Settings:

  • Layer 2 Tunneling Protocol” (L2TP)
  • feup-vpn.up.pt
  • jlopes@fe.up.pt
  • IPsec Settings >
    • Enable IPsec tunnel to L2TP host
    • Pre-shared key: VPN_UPDIGITAL
  • PPP Settings >
    • PAP
    • MSCHAPv2
    • Permitir compressão de dados BSD (Allow BSD data compression)
    • Permitir compressão de dados Deflate (Allow Deflate data compression)
    • Usar compressão de cabeçalho TCP (Use TCP header compression)
    • Use protocol field compression negotiation
    • Use Address/Control compression

Cofigurações L2TP

VPN: INESCTECNet

  • Guide at inesc: HELP
  • OpenVPN configuration file including certificates available here
  • Download the file: ca.pem, cert.pem and key.pem inesctec_vpn_202012.zip
  • Do NOT forward all internet traffic into tunnel
#sudo apt install openvpn openssl
sudo apt install network-manager-openvpn network-manager-openvpn-gnome easy-rsa
  • Download inesctec_202103.ovpn
  • O Ubuntu não aceita a sintaxe de openvpn ⇒ Comentar as linhas 25-29 de inesctec_202103.ovpn
  • Network Manager > importar o ficheiro ovpn, or else:
jlopes@jclell3:~/Downloads> nmcli connection import type openvpn file inesctec_202103.ovpn
Connection 'inesctec_202103' (84dea75c-adbd-4f15-abef-60db387e1627) successfully added.

[inesctec_202103.ovpn]

Connection name: INESCTECNet
Getway: vpn.inesctec.pt:1194
Authentication Type: Password
User name: joao.c.lopes@inesctec.pt
Password: <INESC TEC's directory password>
CA Certificate:  ca.pem file
IPv4 Settings > Routes: "Use this connection only for resources on its network"

3.8 config printers

# get old
cd tmp
rsync -avz "$OLD"/etc/cups .
cd /etc/cups
# config
sudo systemctl stop cups
sudo cp printers.conf printers.conf_safe
sudo cp /home/jlopes/tmp/cups/printers.conf .
sudo diff printers.conf printers.conf_safe
sudo cp /home/jlopes/tmp/cups/ppd/* ppd
sudo service cups restart   # sudo systemctl start cups
sudo service cups status    # sudo systemctl status cups
● cups.service - CUPS Scheduler
     Loaded: loaded (/lib/systemd/system/cups.service; enabled; vendor preset: enabled)
     Active: active (running) since Wed 2023-07-12 20:10:45 WEST; 14s ago
TriggeredBy: ● cups.socket
             ○ cups.path
       Docs: man:cupsd(8)
   Main PID: 50917 (cupsd)
     Status: "Scheduler is running..."
      Tasks: 1 (limit: 37926)
     Memory: 3.1M
        CPU: 729ms
     CGroup: /system.slice/cups.service
             └─50917 /usr/sbin/cupsd -l

jul 12 20:10:45 jclell3 systemd[1]: Starting CUPS Scheduler...
jul 12 20:10:45 jclell3 systemd[1]: Started CUPS Scheduler.
ls -l
-rw-r----- 1 root lp   72187 dez 15  2020 cica.ppd
-rw-r----- 1 root lp   30845 dez  8  2020 DCPJ562DW.ppd
-rw-r----- 1 root lp   22988 set 21  2022 Geral_A4.ppd
-rw------- 1 root root 72190 nov 22  2020 xrx7345.ppd

3.9 config scanner

sudo apt install simple-scan

3.10 printers @ FEUP

# UNOFFICIAL PaperCut Mobility Print Linux command line client
git clone https://github.com/Rewzilla/pc-mobility-print.git
cd pc-mobility-print
python3 cli.py -s print.up.pt -d campus list
Printer Name             | Printer Description
-------------------------+---------------------
MP-GERAL-P-A4            | print
MP-GERAL-P-A3            | print
MP-GERAL-C-A4            | print
MP-GERAL-C-A3            | print
# get connect string with password hash
python3 cli.py -s print.up.pt -d campus -u up230756@up.pt get MP-GERAL-C-A4 # -p SENHA
# http://print.up.pt:9163/printers/MP-GERAL-C-A4/users/up230756%40up.pt/d6800bf**********
python3 cli.py -s print.up.pt -d campus -u up230756@up.pt get MP-GERAL-P-A4
# http://print.up.pt:9163/printers/MP-GERAL-P-A4/users/up230756%40up.pt/51ce1bb**********
sudo service cups stop
sudo vi /etc/cups/printers.conf  # change URI
sudo service cups start

3.11 Configure languages

  • language support (install PT support)
sudo apt install language-pack-pt-base #meta-package
  • Settings > Languages & Region # install missing components

3.12 config Numix Theme

sudo add-apt-repository ppa:numix/ppa
sudo apt update
sudo apt install numix-icon-theme-circle

3.13 config Gnome

sudo apt install gnome-system-monitor gnome-weather gnome-screenshot 

Tweak Tool

sudo apt install gnome-tweaks
gnome-tweaks 
# windows titlebar max & min to the left, enable minimize to click, enable hot corners

Nautilus

gsettings set org.gnome.nautilus.list-view default-visible-columns "['name', 'type', 'size', 'permissions', 'date_modified']"
gsettings set org.gnome.nautilus.list-view default-column-order "['name', 'type', 'size', 'permissions', 'date_modified']"

shell extensions

sudo apt install gnome-shell-extensions gnome-shell-extension-prefs
# list extensions
sudo apt search gnome-shell-extension | more
# use the new extensions app to manage extensions
gnome-extensions-app
# use the Chrome extension to manage gnome extensions
sudo apt install chrome-gnome-shell
# BETTER
# use the extension manager to manage gnome extensions
sudo apt install gnome-shell-extension-manager

In Chrome hit https://extensions.gnome.org/:

  • AlternateTab by fmuellner
  • Applications Menu by fmuellner
  • Apt Update Indicator by franglais125
  • Auto Move Windows by fmuellner [OFF]
  • Caffeine by eon
  • Coverflow Alt-Tab by dsheeler [OFF]
  • Dash to Panel by charlesg99 [OFF]
  • Desktop Icons NG (DING) by rastersoft [built-in]
  • Disconnect Wifi by kgshank
  • Extension list by grroot
  • Launch new instance by fmuellner [OFF]
  • Native Window Placement by fmuellner
  • OpenWeather by skrewball
  • Places Status Indicator [built-in] [OFF]
  • Removable Drive Menu by fmuellner [OFF]
  • Screenshot Window Sizer by fmuellner [OFF]
  • Simple System Monitor by LGiki
  • Sound Input & Output Device Chooser by kgshank
  • Tray icons reloaded by Martin
  • Ubuntu AppIndicators by didrocks [built-in]
  • Ubuntu Dock by didrocks [built-in]
  • User Themes by fmuellner [built-in] [OFF]
  • V-Shell (Vertical Workspaces) by GdH
  • Window List by fmuellner [built-in] [OFF]
  • windowNavigator by fmuellner [built-in]
  • Workspace Indicator by fmuellner [built-in] [OFF]

Nautilus connect to server by sftp

The Gnome file manager (AKA Nautilus) supports a multitude of server protocols, including ssh/sftp. Allowing users to connect over FTP (especially SFTP) through the Gnome file manager is critical since a lot of Linux users rely on this protocol to access, download and upload files to servers and desktops running Linux over SSH.

Click on the “Other Locations” button to take the Nautilus and enter the server address: sftp:/ /lopeses.myqnapcloud.com:37132/.

3.14 Integrated Camera not available

  • The integrated webcam is not recognized, though an external one works fine.
jlopes@jclell3:~> sudo dmesg | grep -i "Camera"
jlopes@jclell3:~> 
jlopes@jclell3:~> sudo apt install v4l-utils
jlopes@jclell3:~> sudo v4l2-ctl --list-devices
Cannot open device /dev/video0, exiting.
jlopes@jclell3:~> sudo ls -l /dev/video*
ls: cannot access '/dev/video*': No such file or directory
  • The next step is to enter your BIOS/UEFI and make sure the webcam is enabled. You can enable and disable the webcam in the BIOS and it may have been disabled inadvertently. You can also consult the website to update your BIOS if necessary.
  • Install the IPU6/IPU6EP stack manually:
sudo add-apt-repository ppa:oem-solutions-group/intel-ipu6
sudo apt install linux-modules-ipu6-generic-hwe-22.04 linux-modules-ivsc-generic-hwe-22.04
sudo apt install libcamhal-ipu6ep0
sudo reboot 
jlopes@jclell3:~> sudo v4l2-ctl --list-devices
ipu6 (PCI:pci:pci0000:00):
	/dev/video1
 
ipu6 (pci:pci0000:00):
	/dev/media0
 
Virtual Camera (platform:v4l2loopback-000):
	/dev/video0
jlopes@jclell3:~> sudo ls -l /dev/video*
crw-rw----+ 1 root video 81, 0 jul 21 08:36 /dev/video0
crw-rw----+ 1 root video 81, 1 jul 21 08:36 /dev/video1
  • Add the video group to your user if this isn't done automatically
jlopes@jclell3:~> sudo adduser jlopes video # sudo usermod -a -G video $LOGNAME
jlopes@jclell3:~> cat /etc/group | grep video
video:x:44:jlopes
  • Workaround to make Cheese useable by disable v4l2 in pipewire # video for linux udev detection (Askubuntu)
sudo vi /usr/share/pipewire/media-session.d/media-session.conf
# comment that line starting with v4l2
 
shutdown now
  • Your integrated webcam should work on Zoom, Skype and OBS now, though not necessarily on Cheese
jlopes@jclell3:~> sudo dmesg |grep ipu6
[    3.725960] intel-ipu6 intel-ipu: enabling device (0000 -> 0002)
[    3.726140] intel-ipu6 intel-ipu: Device 0xa75d (rev: 0x1)
[    3.726164] intel-ipu6 intel-ipu: physical base address 0x6054000000
[    3.726166] intel-ipu6 intel-ipu: mapped as: 0x00000000d5bc7913
[    3.726215] intel-ipu6 intel-ipu: IPU in secure mode
[    3.726218] intel-ipu6 intel-ipu: IPU secure touch = 0x0
[    3.726219] intel-ipu6 intel-ipu: IPU camera mask = 0x0
[    3.742352] intel-ipu6 intel-ipu: IPC reset done
[    3.742357] intel-ipu6 intel-ipu: cpd file name: intel/ipu6ep_fw.bin
[    3.746073] intel-ipu6 intel-ipu: FW version: 20220510
[    3.750401] intel-ipu6 intel-ipu: Found supported sensor OVTI02C1:00
[    3.750584] intel-ipu6 intel-ipu: Connected 1 cameras
[    3.751805] intel-ipu6 intel-ipu: Sending BOOT_LOAD to CSE
[    3.766234] intel-ipu6 intel-ipu: Sending AUTHENTICATE_RUN to CSE
[    3.840826] intel-ipu6 intel-ipu: CSE authenticate_run done
[    3.840861] intel-ipu6 intel-ipu: IPU6-v3 driver version 1.0
[    3.885394] intel-ipu6-psys intel-ipu6-psys0: pkg_dir entry count:8
[    3.885515] intel-ipu6-psys intel-ipu6-psys0: psys probe minor: 0
[   14.297576] intel-ipu6-isys intel-ipu6-isys0: bind ov02c10 3-0036 nlanes is 2 port is 1
[   14.297935] intel-ipu6-isys intel-ipu6-isys0: All sensor registration completed.
  • is the camera available?
jlopes@jclell3:~> sudo dmesg | grep -i "Camera"
[    3.719154] intel-ipu6 intel-ipu: IPU camera mask = 0x0
[    3.738304] intel-ipu6 intel-ipu: Connected 1 cameras
lopes@jclell3:~> ls -ltrh /dev/video*
crw-rw----+ 1 root video 81, 0 jul 26 09:50 /dev/video0
crw-rw----+ 1 root video 81, 1 jul 26 09:50 /dev/video1
jlopes@jclell3:~> v4l2-ctl --list-devices
ipu6 (PCI:pci:pci0000:00):
	/dev/video1

ipu6 (pci:pci0000:00):
	/dev/media0

Intel MIPI Camera (platform:v4l2loopback-000):
	/dev/video0

jlopes@jclell3:~> v4l2-ctl -d /dev/video0 --list-ctrls

User Controls

                    keep_format 0x0098f900 (bool)   : default=0 value=0
              sustain_framerate 0x0098f901 (bool)   : default=0 value=0
                        timeout 0x0098f902 (int)    : min=0 max=100000 step=1 default=0 value=0
               timeout_image_io 0x0098f903 (bool)   : default=0 value=0
jlopes@jclell3:~> cheese

(cheese:94249): cheese-WARNING **: 11:49:47.964: Internal data stream error.: ../libs/gst/base/gstbasesrc.c(3127): gst_base_src_loop (): /GstCameraBin:camerabin/GstWrapperCameraBinSrc:camera_source/GstBin:bin18/GstPipeWireSrc:pipewiresrc1:
streaming stopped, reason not-negotiated (-4)

jlopes@jclell3:~> sudo cheese -d "Intel MIPI Camera"
  • Camera available on VLC and on zoom (in the Browser)
  • not anymore, after a restart
jlopes@jclell3:~> lsmod | grep ipu6
intel_ipu6_isys       159744  0
videobuf2_dma_contig    24576  1 intel_ipu6_isys
videobuf2_v4l2         36864  1 intel_ipu6_isys
videobuf2_common       86016  4 videobuf2_dma_contig,videobuf2_v4l2,intel_ipu6_isys,videobuf2_memops
intel_ipu6_psys       114688  0
intel_ipu6            122880  2 intel_ipu6_isys,intel_ipu6_psys
v4l2_fwnode            40960  2 ov02c10,intel_ipu6_isys
v4l2_async             28672  3 v4l2_fwnode,ov02c10,intel_ipu6_isys
videodev              323584  6 v4l2_async,videobuf2_v4l2,ov02c10,v4l2loopback,intel_ipu6_isys
mc                     81920  6 v4l2_async,videodev,videobuf2_v4l2,ov02c10,intel_ipu6_isys,videobuf2_common
jlopes@jclell3:~> 
jlopes@jclell3:/etc/modprobe.d> grep "ipu" *.conf
jlopes@jclell3:/etc/modprobe.d> sudo modprobe intel_ipu6
jlopes@jclell3:/etc/modprobe.d> sudo modprobe -r intel_ipu6
modprobe: FATAL: Module intel_ipu6 is in use.

  • Some more work (nothing new):

3.15 Make ubuntu faster

* https://prahladyeri.com/blog/2017/09/how-to-trim-your-new-ubuntu-installation-of-extra-fat-and-make-it-faster.html

sudo systemctl disable cups-browsed.service browsed
sudo systemctl disable avahi-daemon
sudo mv /usr/lib/evolution-data-server /usr/lib/evolution-data-server-disabled

4. Build Environment

#sudo apt install build-essential
sudo apt install manpages-dev autoconf automake libtool
sudo apt install flex flex-doc bison bison-doc make perl perl-doc gbase

5. KeepassXC

sudo apt install keepassxc

6. Git

sudo apt install git
# config
git config --global user.name "Correia Lopes"
git config --global user.email jlopes@fe.up.pt
git config --global core.editor emacs
git config --global merge.tool vimdiff

7. Qsync Client

sudo dpkg -i ~/Downloads/QNAPQsyncClientUbuntux64-1.0.9.1627.deb
sudo dpkg -i ~/Downloads/QNAPQfinderProUbuntux64-7.8.4.0323.deb
  • run Applications > QNAPQsyncClient & Qfinder Pro

8. Servers & sys

sudo apt install smbclient # to have CICA printers
sudo apt install vinagre   # a VNC client
sudo apt install ntp 
sudo apt install hwinfo hardinfo
sudo apt install stacer    # dashboard monitor
sudo apt install htop      # nicer top

8.1 Postfix mail transfer agent (MTA)

sudo apt install postfix                   # local, lopeses.myqnapcloud.com
sudo cp /etc/postfix/main.cf /etc/postfix/main.cf_dist
sudo postfix status                        # is it running?
#sudo postconf -e "home_mailbox = Maildir/" # Maildirs instead of Mboxes
#sudo postconf -e "mailbox_command = "      # no Procmail
sudo cp $OLD/main.cf /etc/postfix/main.cf
#sudo postconf compatibility_level=3.6
sudo service postfix restart
jlopes@jclell3:~> sudo diff /etc/postfix/main.cf /etc/postfix/main.cf_dist
7c7
< myorigin = /etc/mailname
---
> #myorigin = /etc/mailname
40,41c40,41
< mydestination = localhost.localdomain, localhost
< relayhost = smtp.fe.up.pt
---
> mydestination = $myhostname, jclell3, localhost.localdomain, localhost
> relayhost = 
45,46c45
< inet_interfaces = all
< home_mailbox = Maildir/
---
> inet_interfaces = loopback-only
jlopes@jclell3:~> cat /etc/mailname 
lopeses.myqnapcloud.com

[main.cf]

8.2 Dovecot for IMAP

sudo apt install dovecot-imapd # installs dovecot-core & ntpdate
# config
sudo systemctl stop dovecot.socket
sudo service dovecot stop
# dovecot.conf
sudo cp /etc/dovecot/dovecot.conf /etc/dovecot/dovecot.conf_dist
diff /etc/dovecot/dovecot.conf $OLD/dovecot.conf
#sudo cp $OLD/dovecot.conf /etc/dovecot/dovecot.conf
# 10-mail.conf
sudo cp /etc/dovecot/conf.d/10-mail.conf /etc/dovecot/conf.d/10-mail.conf_dist
sudo diff /etc/dovecot/conf.d/10-mail.conf_dist $OLD/10-mail.conf_dist
sudo cp $OLD/10-mail.conf /etc/dovecot/conf.d/10-mail.conf
# 10-ssl.conf_dist
sudo cp /etc/dovecot/conf.d/10-ssl.conf /etc/dovecot/conf.d/10-ssl.conf_dist
sudo diff /etc/dovecot/conf.d/10-ssl.conf_dist $OLD/10-ssl.conf
sudo cp $OLD/10-ssl.conf /etc/dovecot/conf.d/10-ssl.conf
sudo service dovecot start
sudo service dovecot status
● dovecot.service - Dovecot IMAP/POP3 email server
     Loaded: loaded (/lib/systemd/system/dovecot.service; enabled; vendor preset: enabled)
     Active: active (running) since Sun 2023-07-09 11:10:15 WEST; 4s ago
       Docs: man:dovecot(1)
             https://doc.dovecot.org/
   Main PID: 22410 (dovecot)
     Status: "v2.3.16 (7e2e900c1a) running"
      Tasks: 4 (limit: 37926)
     Memory: 2.9M
        CPU: 20ms
     CGroup: /system.slice/dovecot.service
             ├─22410 /usr/sbin/dovecot -F
             ├─22411 dovecot/anvil
             ├─22412 dovecot/log
             └─22413 dovecot/config

jul 09 11:10:15 jclell3 systemd[1]: Starting Dovecot IMAP/POP3 email server...
jul 09 11:10:15 jclell3 dovecot[22410]: master: Dovecot v2.3.16 (7e2e900c1a) starting up for imap (core dumps disabled)
jul 09 11:10:15 jclell3 systemd[1]: Started Dovecot IMAP/POP3 email server.

[dovecot.conf] [10-mail.conf] [10-ssl.conf]

Run servers on demand

# sudo service dovecot stop  # start when needed
# sudo systemctl disable dovecot
 
# start POSTFIX if needed
jlopes@jclell3:~> sudo service postfix stop
jlopes@jclell3:~> sudo systemctl disable postfix
Synchronizing state of postfix.service with SysV service script with /lib/systemd/systemd-sysv-install.
Executing: /lib/systemd/systemd-sysv-install disable postfix
Removed /etc/systemd/system/multi-user.target.wants/postfix.service.
jlopes@jclell3:~> sudo service postfix status
sudo systemctl disable postfix
○ postfix.service - Postfix Mail Transport Agent
     Loaded: loaded (/lib/systemd/system/postfix.service; disabled; vendor preset: enabled)
     Active: inactive (dead)
       Docs: man:postfix(1)

9. Thunderbird

sudo apt install thunderbird
sudo apt install thunderbird-locale-en-gb thunderbird-locale-pt-pt

ubuntu1804-minimal

sudo service dovecot start  # start when needed
sudo service dovecot stop   # stop if NOT needed
  • jlopes@localhost
    • Server Type: IMAP Mail Server
    • Server name: localhost
    • User name: jlopes
    • Port: 143 ← 993
    • Connection security: None
    • Authentication: normal password
  • up230756@imap-mail.up.pt
    • Server Type: IMAP Mail Server
    • Server name: mail.up.pt
    • User name: up230756@up.pt
    • Port: 993
    • Connection security: SSL/TLS
    • Authentication: NTLM
  • correia.lopes@gmail.com
    • Server Type: IMAP Mail Server
    • Server name: imap.gmail.com
    • User name: correia.lopess@gmail.com
    • Port: 993
    • Connection security: SSL/TLS
    • Authentication: OAuth2
  • up230756@smtp-mail.up.pt
    • Server name: mail.up.pt
    • User name: up230756@up.pt
    • Port: 587
    • Authentication: NTLM
    • Connection method: STARTTLS
  • jlopes@smtp.gmail.com
    • Server name: smtp.gmail.com
    • User name: correia.lopes@gmail.com
    • Port: 465
    • Authentication: OAuth2
    • Connection method: SSL/TLS

Novo email UP (31/05/2022):

10. Java

# Install OpenJDK
apt search openjdk | grep openjdk-
sudo apt install openjdk-8-jdk
sudo apt install openjdk-11-jdk
sudo apt install openjdk-18-jdk
# Confirm installation
java --version
# Switch between installed versions
sudo update-alternatives --config java
sudo update-alternatives --config javac

11. Ubuntu Software

Installed from snaps:

  • skype
  • signal-desktop
  • spotify
  • inkscape
  • Xournal++
  • graphwhiz
  • Freeplane
snap install xsype
sudo snap install signal-desktop

12. Google Chrome

cd Downloads/
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo apt install ./google-chrome-stable_current_amd64.deb

13. Zoom

cd Downloads
wget https://zoom.us/client/latest/zoom_amd64.deb
sudo apt install ./zoom_amd64.deb
# fix dependencies
sudo apt install -f # installs libegl1-mesa libgl1-mesa-glx libxcb-cursor0 libxcb-xtest0
# run it
zoom
# uninstall
sudo apt remove --purge zoom
  • The screen sharing options in Wayland are currently limited. To share just a specific application, you need to launch your Linux session with Xorg instead. This is a known issue and will be fixed in a future Zoom client release. https://support.zoom.us/hc/en-us/articles/6634039380877
  • solution: Login w/ "Ubuntu on Xorg" at the login
  • install zoom-client from Ubuntu software: NOPE!
sudo snap install core
sudo snap install zoom-client
snap run zoom-client   # run it

14. play video

  • Install the missing codecs and decoders from Ubuntu Desktops; also installs fonts, …
sudo apt install libdvdnav4 gstreamer1.0-plugins-bad gstreamer1.0-plugins-ugly libdvd-pkg # libdvdread4
sudo apt install ubuntu-restricted-extras

15. VLC

sudo apt install vlc

16. LibreOffice

sudo apt install libreoffice 
#sudo apt install libreoffice-pdfimport
#sudo apt install libreoffice-l10n-pt libreoffice-help-pt
#sudo apt install libreoffice-l10n-en-gb libreoffice-help-en-gb

ubuntu1804-minimal

17. TeX

sudo apt install texlive texlive-base texlive-latex-recommended texlive-extra-utils # texlive-generic-extra
sudo apt install texlive texlive-latex-extra-doc texlive-pictures-doc
sudo apt install texlive-fonts-recommended texlive-fonts-extra lmodern
sudo apt install texlive-lang-portuguese
sudo apt install latexmk latexdiff
sudo apt install texlive-humanities texlive-science texlive-publishers
sudo apt install dspdfviewer  # Dual-Screen PDF Viewer for LaTeX-beamer
#sudo apt install latex-beamer # NOT available

18. Office-ish

sudo apt install emacs crypt++el elpa-markdown-mode auctex 
#sudo apt install emacs haskell-mode python-mode crypt++el auctex php-elisp
#sudo apt install markdown
sudo apt install ispell iportuguese ibritish ifrench ispanish wbritish-large
sudo apt install aspell aspell-pt aspell-uk spell
sudo apt install gedit gedit-common gedit-plugins gedit-latex-plugin
#sudo apt install okular okular-backend-odp okular-extra-backends
sudo apt install imagemagick 
#snap sudo apt install inkscape 
#sudo apt install dia dia-shapes
sudo apt install gimp gimp-data gimp-data-extras
#snap sudo apt install graphviz
#sudo apt install xfig xfig-doc xfig-libs transfig fig2ps
sudo apt install a2ps psutils pstoedit gv gsfonts-x11  # Package 'xpdf' has no installation candidate
#sudo apt install pdfjam  # NOT available
sudo apt install recode recode-doc
sudo apt install unace rar unrar p7zip-rar p7zip zip unzip sharutils uudeview mpack arj cabextract file-roller lunzip lzip
sudo apt install planner # project management
sudo apt install freeplane # mindmaps
sudo apt install ttf-mscorefonts-installer  # Microsoft fonts
sudo fc-cache -vr  # build fresh font information cache files

19. Aspell PT

cd ~/tmp
#get latest
wget http://natura.di.uminho.pt/download/sources/Dictionaries/aspell6/LATEST/aspell6.pt-latest.tar.bz2
#uncompress it
bzip2 -d aspell6.pt-latest.tar.bz2
tar xvf aspell6.pt-latest.tar
#make & install
cd aspell6-pt_PT-*
./configure
Finding Dictionary file location ... /usr/lib/aspell
Finding Data file location ... /usr/lib/aspell
make
/usr/bin/prezip-bin -d < pt_PT.cwl | /usr/bin/aspell  --lang=pt_PT create master ./pt_PT.rws
sudo make install
sudo mkdir -p /usr/lib/aspell/
sudo cp pt_PT.rws pt_PT.multi /usr/lib/aspell/
sudo chmod 644 /usr/lib/aspell/pt_PT.rws /usr/lib/aspell/pt_PT.multi
sudo cp pt_PT.dat pt_PT_repl.dat pt_PT_affix.dat /usr/lib/aspell/
sudo chmod 644 /usr/lib/aspell/pt_PT.dat /usr/lib/aspell/pt_PT_repl.dat /usr/lib/aspell/pt_PT_affix.dat

20. Pandoc

# pandoc universal document converter
sudo apt install pandoc texlive-xetex texlive-luatex pandoc-citeproc context wkhtmltopdf
# latest version
cd ~/Downloads
wget https://github.com/jgm/pandoc/releases/download/2.10/pandoc-2.10-1-amd64.deb
sudo dpkg -i ~/Downloads/pandoc-2.10-1-amd64.deb

21. Python3

# Python needed libs
sudo apt install python3-numpy python3-scipy python3-matplotlib python3-sympy
sudo apt install python3-yaml python3-lxml
sudo apt install mypy     # type-checking
# Jupyter NB
sudo apt install jupyter-notebook python-notebook-doc
# Spyder IDE
#sudo apt install spyder3  # needs Python 3
#sudo apt install python3-spyder-unittest
#sudo apt install python3
# FPRO projects
sudo apt install python3-pygame python-pygame-doc
# pip
sudo apt install python3-pip
# NB as slides using reveal.js
pip3 install RISE  # to display slides as 

VS code

sudo dpkg -i ~/Downloads/code_1.80.0-1688479026_amd64.deb
  • Python installation
    • Launch VS Code Quick Open (Ctrl+P), paste ext install ms-python.python and press enter.

Archimate

DELETEME

> sudo snap install archimate
archimate 4.7.1 from Wouter van Bommel (woutervb) installed
> archimate  ## NOT WORKING

22. Mendeley

mv ~/Downloads/mendeley-reference-manager*.AppImage ~/box/bib/
chmod a+x ~/box/bib/mendeley-reference-manager-2.93.0-x86_64.AppImage
sudo apt install libfuse2  # needed in Ubuntu 22.04
 
# execute Mendeley
~/box/bib/mendeley-reference-manager-2.93.0-x86_64.AppImage

23. autenticacao.gov

wget https://aplicacoes.autenticacao.gov.pt/apps/pteid-mw_ubuntu22_amd64.deb
sudo apt install ~/Downloads/pteid-mw_ubuntu22_amd64.deb
# run it from Applications > 

24. Install Miniconda

DELETEME

# get Miniconda3-latest-Linux-x86_64.sh
cd ~/Downloads
wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh
 
# Install Miniconda3
bash Miniconda3-latest-Linux-x86_64.sh -u  # as user
#[/home/jlopes/miniconda3] >>> 
 
# test conda
conda list
 
# see modifications
tail -18 ~/.bashrc
 
# for changes to take effect
source ~/.bashrc
 
# conda's base environment not be activated on startup, 
conda config --set auto_activate_base false
 
# Install Spyder3
conda install spyder
 
# Install Jupyter
conda install jupyter
 
# install RISE (for slides)
conda install -c conda-forge rise
 
# install some other useful packages
conda install numpy matplotlib
 
# use
conda activate
spyder
jupyter-notebook nb.ipynb
conda deactivate

25. Docker

DELETEME

# https://docs.docker.com/install/
 
sudo apt update
sudo apt install apt-transport-https ca-certificates curl software-properties-common
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
sudo apt update
sudo apt install docker-ce
docker run hello-world # make sure that the installation worked
# docker: Got permission denied while...
sudo usermod -a -G docker $USER # jlopes
docker container list -a
 
# https://docs.docker.com/compose/install/#install-compose
 
sudo curl -L https://github.com/docker/compose/releases/download/1.18.0/docker-compose-`uname -s`-`uname -m` -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose
docker-compose --version # verify that you have Docker Compose installed.

26. PgAdmin4

DELETEME

sudo apt-get install curl ca-certificates
curl https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -
sudo sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt/ $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
sudo apt update
sudo apt install pgadmin4
# start the server
pgadmin4

Available at: http://127.0.0.1:44525/


Correia Lopes, 07/07/2023 23:30

doc/linux/ubuntu2204-jclell3.txt · Last modified: 12/04/2024 14:53 by Correia Lopes

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki