Notes on how to setup proper dual boot Win/Linux
on my Asus Zenbook UX534FT
( ! sound not working for now - except in HDMI ) / fixed by script 2020-07-28
-
Disable bitlocker
-
Shrink partition to make some space available ( > 50Go) - unformated
-
Download ubuntu iso from https://ubuntu.com/download/desktop
-
Create bootable usb disk using balenaEtcher
-
Disable Fast Startup
power options / Change settings that are currently unavailable / uncheck FastStartup
- disable fastboot
- disable secure boot
- Select install ubuntu
- follow setup:
- select language (English)
- select keyboard layout (French - French (AZERY)) - check it's ok.
- select normal installation - use nvidia drivers...
- select install along Windows (it will detect and install it on empty partition created earlier)
- define user / password / laptop name...
- continue...
- it will reboot (remove usb stick)
All steps below have been automated using script.
download install.sh, allow execution and run it
./install.sh
-
disable Screenpad display
- settings / devices...
-
set ubuntu to use LocalTime to avoid time difference in windows when rebooting:
timedatectl set-local-rtc 1 --adjust-system-clock
-
check graphic card used
-
settings / details
-
and/or
nvidia-smi
-
- create a folder ( ex: in /home/user/Windows )
- find windows partition UUID:
ls -l /dev/disk/by-partlabel/
ls -l /dev/disk/by-uuid/
- edit fstab
sudo gedit /etc/fstab
-
add line in fstab (it will be mounted after reboot)
UUID=<uuid found before> <path_to_folder_created> ntfs-3g defaults 0 0
-
force mounting now:
sudo mount -a
sudo apt update
sudo apt upgrade
- install dconf editor
- from store
- launch it and go to
- org / gnome / shell / extensions / dash-to-dock
- turn off show-mounts option
-
create a file /etc/rc.local
sudo nano /etc/rc.local
-
copy script in file
#!/bin/bash hda-verb /dev/snd/hwC0D0 0x20 0x500 0xf hda-verb /dev/snd/hwC0D0 0x20 0x477 0x74 exit 0
-
setup permissions / make it executable
sudo chmod +x /etc/rc.local
-
download and install
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb sudo apt install ./google-chrome*.deb
sudo add-apt-repository ppa:phoerious/keepassxc
sudo apt update
sudo apt install keepassxc
- install Grub Customizer
- modify order for booting (ex: windows first ...)
- select image etc...
sudo apt install git
- download latest deb release from https://github.com/shiftkey/desktop/releases
- install it
sudo apt install ./GithubDesktop*.deb
- Launch and configure
wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh
sh Miniconda3-latest-Linux-x86_64.sh
-
install Jupyter notebook (in base env)
conda install jupyter
-
install kernels in select env
conda install ipykernel
-
install specific verison (ex 3.7)
-
download from python Gzipped tarball https://www.python.org/downloads/source/ or
wget https://www.python.org/ftp/python/3.7.8/Python-3.7.8.tgz
-
uncompress
sudo tar xzf Python-3.7.8.tgz
-
Install required lib
sudo apt-get install build-essential libsqlite3-dev sqlite3 bzip2 libbz2-dev \ zlib1g-dev libssl-dev openssl libgdbm-dev libgdbm-compat-dev liblzma-dev libreadline-dev \ libncursesw5-dev libffi-dev uuid-dev
-
compile (make alt install to keep existing configsudo)
cd Python-3.7.8 sudosudo ./configure --enable-optimizations sudo make altinstall
-
check
python3.7 -V
-
check install path
which python3 which python3.7
-
-
install pip / venv
sudo apt install python3-pip sudo apt install python3-venv
-
Use:
- python3 for default python3 install
- python3.7 for specific version
- avoid python: for python 2.7
- once in a virtual env: use python and pip
-
Example
-
python 3 (default version)
python3 -m venv venv/test3 source venv/test3/bin/activate pip list
returns: /usr/bin/python3
-
python 3 (default version)
python3.7 -m venv venv/test37 source venv/test37/bin/activate pip list
returns: /usr/local/bin/python3.7
-
wget -qO - https://typora.io/linux/public-key.asc | sudo apt-key add -
sudo add-apt-repository 'deb https://typora.io/linux ./'
sudo apt update
sudo apt install typora
sudo apt install apt-transport-https ca-certificates curl software-properties-common
curl -fsSL https://download.sublimetext.com/sublimehq-pub.gpg | sudo apt-key add -
sudo add-apt-repository "deb https://download.sublimetext.com/ apt/stable/"
sudo apt update
sudo apt install sublime-text
curl https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > packages.microsoft.gpg
sudo install -o root -g root -m 644 packages.microsoft.gpg /usr/share/keyrings/
sudo sh -c 'echo "deb [arch=amd64 signed-by=/usr/share/keyrings/packages.microsoft.gpg] https://packages.microsoft.com/repos/vscode stable main" > /etc/apt/sources.list.d/vscode.list'
sudo apt-get install apt-transport-https
sudo apt-get update
sudo apt-get install code
-
docker
- install
sudo apt install apt-transport-https ca-certificates curl gnupg-agent 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-ce-cli containerd.io
- check
sudo systemctl status docker
-
post install / permissions as non root user
sudo usermod -aG docker ${USER}
-
docker compose (1.28.2) official doc https://docs.docker.com/compose/install/
sudo curl -L "https://github.com/docker/compose/releases/download/1.28.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose sudo chmod +x /usr/local/bin/docker-compose
sudo add-apt-repository ppa:serge-rider/dbeaver-ce
sudo apt-get update
sudo apt-get install dbeaver-ce
sudo apt install gimp
-
remove old version of java if needed
sudo apt remove openjdk-11-jre-headless openjdk-11-jre openjdk-11-jdk-headless openjdk-11-jdk
-
install jdk and jre
sudo apt install openjdk-8-jdk sudo update-alternatives --config java
-
Download/extract
-
launch in pentaho folder
sh spoon.sh
-
tip "make it executable"
right-click on spoon.sh : properties : permissions : Allow executing file as program
in file explorer menu : preferences : behavior : executable text files : run them (or ask what to do)
-
sudo apt install -y byobu zsh fonts-powerline
sh -c "$(wget -O- https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
nano ~/.zshrc
# change theme line to agnoster
ZSH_THEME="agnoster"
touch ~/.byobu/.tmux.conf
echo "set -g mouse on" >> ~/.byobu/.tmux.conf
echo "set -g mouse-utf8 on" >> ~/.byobu/.tmux.conf
echo "set -g default-shell /usr/bin/zsh" >> ~/.byobu/.tmux.conf
echo "set -g default-command /usr/bin/zsh" >> ~/.byobu/.tmux.conf
- in terminal preferences, create a profile "byobu"
- in command tab, select run a custom command instead of my shell
- custom command: /usr/bin/byobu