- temporary:
sudo service stop mydesktop
- permanent:
sudo systemctl disable mydesktop
- get local DNS server address:
cat /etc/resolv.conf
- get list of DNS servers:
netplan get all
- show who is listening on port 53
netstat -peanut
(withoutlsof
)- usually this is
systemd-resolve
- usually this is
service systemd-resolved status
systemctl suspend
Needed that to run YourKit Java heap analyzer on a 34 GB heap dump.
from https://linuxize.com/post/how-to-add-swap-space-on-ubuntu-18-04/
sudo fallocate -l 1G /swapfile
sudo chmod 600 /swapfile
sudo mkswap /swapfile
sudo swapon /swapfile
sudo swapon --show
This is temporary, otherwise an entry should go into /etc/fstab
.
sudo apt-get install network-manager-openconnect-gnome
then go to System settings (restart if they are already running), Network, VPN, setup AnyConnect
from https://itsfoss.com/install-git-ubuntu/
sudo add-apt-repository ppa:git-core/ppa
sudo apt update
sudo apt install git
Handy for misconfigured IPv6 networks (turning off IPv6 via Network UI e.g. for WiFi does not work on Ubuntu 19.10):
sudo sysctl -w net.ipv6.conf.all.disable_ipv6=1
sudo sysctl -w net.ipv6.conf.default.disable_ipv6=1
sudo sysctl -w net.ipv6.conf.lo.disable_ipv6=1
ip a
Note: this has to be applied whenever interface (such as WiFi) changes/reconnects. To disable it permanently, it has to be put into config file under /etc/sysctl.d/
.
sudo apt-get install solaar-gnome3
and then launch from applications. Icon will show up in the toolbar.
Asked on https://askubuntu.com/questions/834856/how-to-install-only-javadoc?newreg=62db87f72f4846549a894778bbab3357 , answer on https://www.digitalocean.com/community/tutorials/how-to-install-java-with-apt-get-on-ubuntu-16-04 :
sudo apt-get install default-jdk
cat << EOF > /etc/apt/apt.conf.d/00proxy
Acquire::http::proxy "http://www-proxy.example.com:80/";
Acquire::ftp::proxy "http://www-proxy.example.com:80/";
Acquire::https::proxy "http://www-proxy.example.com:80/";
EOF
Needed to get microSD card from Android to mount:
sudo apt-get install exfat-fuse exfat-utils
sudo apt-get install unity-tweak-tool
Workspace settings -> Additional -> Focus mode: mouse
sudo apt-get install texlive-full
texlive-latex-base
is not enough because it does not contain seminar.sty
per https://www.cyberciti.biz/faq/how-to-add-install-man-pages-on-ubuntu-linux/
For Pthread APIs:
apt-cache search manpages | egrep 'manpages-(dev|posix)'
apt-get install manpages-posix-dev
which package delivers given file:
dpkg -S /bin/ls
what files are delivered by (installed) package:
dpkg-query -L <pkg>