It’s been a while after my sound on Ubuntu 20.04 didn’t working. I’ve been tried many way to fix the sound but still buggy. So, I decided to reinstall a fresh Ubuntu 20.04.02 LTS. The reinstall process is exciting and also suck tho, seems like repeat events that have ever existed but sometimes forget what to do.
In this article, I give my work-flow in configure and customize an Ubuntu from fresh installation. It can also be applied to others Debian based Distro, like Mint, Kubuntu, Xubuntu with several changes but i just give the point. I don’t cover a whole detail process, I cite the reference for further step.
1. Change to Mirror Repository.
Sometimes, the built-in repository give an error if I do “apt-get update”, so I need to change the repository. Beside that It will help get the best server that can improve package downloading time.
Open “Software & Updates”, “On Ubuntu Software” tab choose drop-down menu beside “Downloaded from :”, then click “Select Best Server”, finally click “Choose Server”.
If I encounter an error, just choose the “Main Server”.
2. Do Update and Upgrade.
As usual I need to update the obsolete package in the system, run this command for Ubuntu or Debian based
$ sudo apt update && sudo apt upgrade && sudo apt dist-upgrade
3. Change Theme.
I love dark theme style that prevent from eye strain. I choose Mojave-dark theme and follow this tutorial.
4. Change Terminal Theme.
This is must have step as I play with terminal often. I customize the terminal with “oh-my-bash” and choose “powerline” as theme.
Install font dependency
$ sudo apt-get install fonts-powerline
5. Install Some Programming Development Stuff
5.1 Anaconda
It’s most popular python data-science virtual environment that has various built-in package. I install by following this tutorial
The problem in Anaconda is “(base)” that always active if you do “conda init”, so I prefer to disable auto base activate and use wrapper in 5.3.
5.2 ROS
Robot Operating System is the most important for me. I need for doing thesis and experiment with robotics. I install the Noetic Desktop Full version for Ubuntu 20.04 by following this tutorial.
After that, follow this tutorial to setup environment.
5.3 Environment Wrapper
ROS and anaconda are not friends as Anaconda is a snake and ROS is a turtle. I mean, Anaconda can change the source of the environment, it automatically change the built-in python to its venv (virtual environment). The solution is using Conda Wrapper
$ git clone https://github.com/rickstaa/.ros_conda_wrapper.git
$ chmod +x install.sh
$ ./install.sh
5.4 IDE
Visual Studio Code is most familiar and free to use IDE but has limitation for specific programming language and that why i rarely use VSC. I just use VSC for creating and editing LaTex document. For VSC installation just go to Ubuntu Software, and find Visual Studio Code.
I prefer use IDE from JetBrains because why not. JetBrains provided the toolbox for easy management and installation.
I installed GoLand for Go development, WebStrom for web development, PyCharm Professional for python development, and Android Studio for mobile development. Just click-click and finished, easy as fck.
5.5 Docker
I bring ship to my development apps for more faster development. Container, container, container in the ship, we go to cloud~~~ (it should plane not ship, but whatever).
Install docker by following the tutorial on official documentation.
After installation I need to setup several things to run docker as non-root user.
$ sudo usermod -aG docker $USER
Log out, and run command again in terminal
$ newgrp docker
Check docker is working
$ docker run hello-world
One more things to do is install docker-compose. I follow this tutorial.
6. Securing my Network Traffic
I use WireGuard for tunneling my connection. I’ve been deploy WG server with DoH (DNS over HTTPs) and ads block for my daily use. Just add some configuration file, and set it as service for run every boot.
Install
$ sudo apt install wireguard
After some configuration in /etc/wireguard/zeroserver.conf. Try to run the interface
$ sudo wg-quick up zeroserver
Then enable wg-quick service for running every booting.
$ sudo systemctl enable wg-quick@zeroserver
Finally, check the interface by enter following command
$ sudo wg show
7. Change Screen Brightness and Color Temperature
For keeping my eye comfort is by changing the brightness color temperature to warm and lowering the brightness. I use “brightness-control” package. I need to set some several configuration, set the brightness level, then choose color temperature to 2850K 100W Tungsten, then click “file” > “save current as default”.
Move to terminal set it to service for automatically run after desktop loading by following command
$ mkdir -p ~/.config/systemd/user
$ nano ~/.config/systemd/user/brightness_control.service
Fill the brightness_control.service with this script
[Unit]
Description=Change brightness on every reboot
PartOf=graphical-session.target
[Service]
ExecStart=bash -c 'sleep 5; brightness-controller'
Type=oneshot
[Install]
WantedBy=graphical-session.target
After that I need to set service enable for booting.
$ chmod 644 ~/.config/systemd/user/brightness_control.service
$ systemctl --user enable backup_reminder.service
$ systemctl --user daemon-reload
8. Install NVIDIA and CUDA 11
This is little bit tricky to enable NVIDIA and working NVIDIA without problem in Ubuntu, make sure to disable secure boot on BIOS, for easier way is just go to “Additional Driver” and select top option then apply.
After finished installation, then reboot.
Check for NVIDIA installation
$ nvidia-smi
CUDA is used to do hyper computation on TensorFlow, I prefer to install using docker rather manually. Follow this guide for TensorFlow Docker with CUDA GPU installation.
I created ZeroTF Docker Stack for playing with TensorFlow GPU enabled.
9. Install Additional Software that I need.
Additional software for multimedia : VLC, Spotify, Gimp
Additional sofware for office : WPS-office
Additional software for browser : Chromium
Leave a Reply