Saturday, 22 November 2014

Archlinux with Plasma 5 installation

last updated: Feb. 23, 2015

First Connect to the internet
Next is partitioning and mounting
After that installing
Note: in partitioning and mounting step you should have mounted the partition you want to have as root on /mnt for the following commands to be right:
Install the basic packages you want to the new root. In my case its the following which installs archlinux and plasma 5 with sddm desktop display manager:
# pacstrap -i /mnt base base-devel sddm plasma
Generate an fstab
# genfstab -U -p /mnt >> /mnt/etc/fstab
Make sure fstab looks right
# nano /mnt/etc/fstab

Chroot and configure the base system

# arch-chroot /mnt /bin/bash
Locale
Edit locale.gen and uncomment en_US.UTF-8 UTF-8
nano /etc/locale.gen
Generate the locale(s) specified in /etc/locale.gen:
# locale-gen
Create the /etc/locale.conf file substituting your chosen locale:
# echo LANG=en_US.UTF-8 > /etc/locale.conf
Export substituting your chosen locale:
# export LANG=en_US.UTF-8
Create a symbolic link /etc/localtime to your subzone file /usr/share/zoneinfo/Zone/SubZone using this command:
# ln -s /usr/share/zoneinfo/Zone/SubZone /etc/localtime
I use:
# ln -s /usr/share/zoneinfo/America/Belize /etc/localtime
Hardware clock
Use either UTC (recommended):
# hwclock --systohc --utc
localtime (discouraged; used by default in Windows):
# hwclock --systohc --localtime
Hostname
# echo myhostname > /etc/hostname
Add the same hostname to /etc/hosts:
# nano /etc/hosts

---------------------------------------------------
#
# /etc/hosts: static lookup table for host names
#

#<ip-address> <hostname.domain.org> <hostname>
127.0.0.1 localhost.localdomain localhost myhostname
::1  localhost.localdomain localhost

# End of file
Set the root password
Set the root password with:
# passwd
Install and configure a bootloader
I use either syslinux or grub.
See syslinux or grub for details or check the beginners guide

Users and groups Add a user. examples:
# useradd -m -G wheel -s /bin/bash archie
# useradd -m -g users -G wheel -s /bin/bash archie
Give the user a password:
passwd archie
Add user info
# chfn archie
Read more about users and groups here.
To be able to run commands with sudo uncomment %wheel ALL=(ALL) ALL from the /etc/sudoers file:
# nano /etc/sudoers
-----------------------------------------------------------------------
## Uncomment to allow members of group wheel to execute any command
 %wheel ALL=(ALL) ALL
Display server
Install xorg-server:
# pacman -S xorg-server
Display Driver
First, identify your card:
$ lspci | grep VGA
Note: if you don't get any output, try looking for a 3D controller instead:
# lspci | grep 3D
Then install an appropriate driver. You can search the package database for a complete list of open-source video drivers:
# pacman -Ss xf86-video
Or check this page.
You might also want to install touchpad drivers if you have laptop.
# pacman -S xf86-input-synaptics 
Finishing Up the Installation
Some things you'll probably want to install before you reboot into your new installation is a browser, terminal, and also kmix (sound aplet in system tray). I chose firefox for browser and konsole for a terminal.
# pacman -S firefox kdemultimedia-kmix konsole
Enable SDDM and NetworkManager with:
# systemctl enable sddm; systemctl enable NetworkManager
Exit out of chroot:
# exit
Unmount partitions:
# umount -R /mnt
Reboot:
# reboot
Additional Packages
You might want to install additional packages example:
$ sudo pacman -S kdebase-dolphin kdemultimedia-ffmpegthumbs kdegraphics-thumbnailers exfat-utils fuse-exfat ntfs-3g kio-mtp dosfstools gparted thunderbird firefox ktorrent smplayer amarok gstreamer0.10-plugins kate gimp kdegraphics-okular gwenview digikam blender kdenlive p7zip unrar unzip zip cups cups-pdf gutenprint system-config-printer flashplugin networkmanager-openvpn openssh libreoffice hunspell hunspell-en k3b cdrdao dvd+rw-tools oxygen-gtk3 oxygen-gtk2 wget ntp firefox-adblock-plus
For the thumbnailers to be used you need to configure it in dolphin
Cups and ssh you need to enable yet with:
$ sudo systemctl enable org.cups.cupsd; sudo systemctl enable sshd
Then reboot or run the following command for it to work:
$ sudo systemctl start cups; sudo systemctl start sshd
You might want to install additional printer drivers:
$ sudo pacman -S gutenprint foomatic-db foomatic-db-engine foomatic-db-nonfree hplip splix foo2zjs
Speed Up applications startup in kde
User Rob wrote on his blog this "magic trick" to improve application start-up time by 50-150ms. To enable it, create this folder in your home:
$ mkdir -p ~/.compose-cache/
Install extra fonts
$ sudo pacman -S ttf-bitstream-vera ttf-dejavu ttf-freefont ttf-linux-libertine ttf-oxygen ttf-droid ttf-liberation ttf-ubuntu-font-family


My combined bash history of installing Arch Linux and Plasma 5 with additional applications:
Note: do not copy/paste the following commands unless you know what you're doing.
ping google.com
lsblk
fdisk /dev/sda
mkswap /dev/sda1
mkfs.ext4 /dev/sda2
mkfs.ext4 /dev/sda3
swapon /dev/sda1
mount /dev/sda2 /mnt
mkdir /mnt/home
mount /dev/sda3 /mnt/home
pacstrap -i /mnt base base-devel sddm plasma-next
genfstab -U -p /mnt >> /mnt/etc/fstab
nano /mnt/etc/fstab
arch-chroot /mnt /bin/bash
nano /etc/locale.gen
locale-gen 
echo LANG=en_US.UTF-8 > /etc/locale.conf
export LANG=en_US.UTF-8
ln -s /usr/share/zoneinfo/America/Belize /etc/localtime
hwclock --systohc --utc
echo jeromy-lenovo > /etc/hostname
nano /etc/hosts
passwd
pacman -S gptfdisk syslinux
syslinux-install_update -iam
nano /boot/syslinux/syslinux.cfg
useradd -m -G wheel -s /bin/bash jeromy
passwd jeromy
chfn jeromy
nano /etc/sudoers
pacman -S xorg-server xf86-video-intel
nano /etc/sddm.conf
systemctl enable sddm; systemctl enable NetworkManager
pacman -S konsole firefox kdemultimedia-kmix
pacman -S pulseaudio-alsa libcanberra-pulse
exit
umount -R /mnt
reboot
sudo pacman -S kdebase-dolphin kdemultimedia-ffmpegthumbs kdegraphics-thumbnailers exfat-utils fuse-exfat ntfs-3g kio-mtp dosfstools gparted thunderbird firefox ktorrent smplayer amarok gstreamer0.10-plugins kate gimp kdegraphics-okular gwenview digikam p7zip unrar unzip zip cups cups-pdf gutenprint system-config-printer flashplugin networkmanager-openvpn openssh libreoffice hunspell hunspell-en k3b cdrdao dvd+rw-tools oxygen-gtk3 oxygen-gtk2 wget ntp firefox-adblock-plus
sudo systemctl enable org.cups.cupsd; sudo systemctl enable sshd
sudo systemctl start org.cups.cupsd; sudo systemctl start sshd
sudo pacman -S ttf-bitstream-vera ttf-dejavu ttf-freefont ttf-linux-libertine ttf-oxygen ttf-droid ttf-liberation ttf-ubuntu-font-family
cd /tmp
curl -O https://aur.archlinux.org/packages/pa/package-query/package-query.tar.gz
tar zxvf package-query.tar.gz
cd package-query
makepkg -si
cd ..
curl -O https://aur.archlinux.org/packages/ya/yaourt/yaourt.tar.gz
tar zxvf yaourt.tar.gz
cd yaourt
makepkg -si
yaourt -S dropbox
reboot

No comments:

Post a Comment