This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
linux:arch_workstation_setup [2018/06/11 17:23] bmiddha created |
linux:arch_workstation_setup [2021/05/02 21:36] (current) |
||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ====== Arch Workstation Setup ====== | ||
Boot into archiso | Boot into archiso | ||
- | Partitions | + | ===== Partitions ===== |
Need MBR partition scheme | Need MBR partition scheme | ||
Line 9: | Line 10: | ||
</code> | </code> | ||
- | UIUC mirror | + | ===== UIUC mirror ===== |
<file|/etc/pacman.d/mirrorlist> | <file|/etc/pacman.d/mirrorlist> | ||
## UIUC | ## UIUC | ||
- | Server = http://cosmos.cites.illinois.edu/pub/archlinux/$repo/os/$arch | + | Server = http://mozart.acm.cs/mirror/archlinux/$repo/os/$arch |
</file> | </file> | ||
- | Time | + | ===== Time ===== |
<code> | <code> | ||
timedatectl set-ntp true | timedatectl set-ntp true | ||
</code> | </code> | ||
- | Install arch | + | ===== Install arch ===== |
<code> | <code> | ||
pacstrap /mnt base base-devel | pacstrap /mnt base base-devel | ||
</code> | </code> | ||
- | Swap | + | ===== Swap ===== |
<code> | <code> | ||
fallocate -l 6G /mnt/swapfile | fallocate -l 6G /mnt/swapfile | ||
- | mkswap /mnt/swapfile | ||
chmod 600 /mnt/swapfile | chmod 600 /mnt/swapfile | ||
+ | mkswap /mnt/swapfile | ||
swapon /mnt/swapfile | swapon /mnt/swapfile | ||
</code> | </code> | ||
- | Generate fstab | + | ===== Generate fstab ===== |
<code> | <code> | ||
genfstab -U /mnt >> /mnt/etc/fstab | genfstab -U /mnt >> /mnt/etc/fstab | ||
</code> | </code> | ||
- | replace /mnt/swapfile with /swapfile in fstab | + | replace /mnt/swapfile with /swapfile in /etc/fstab |
<code> | <code> | ||
/swapfile none swap ........ | /swapfile none swap ........ | ||
</code> | </code> | ||
- | Chroot | + | ===== Chroot ===== |
<code> | <code> | ||
arch-chroot /mnt | arch-chroot /mnt | ||
</code> | </code> | ||
- | Timezone | + | ===== Timezone ===== |
+ | <code> | ||
ln -sf /usr/share/zoneinfo/Region/City /etc/localtime | ln -sf /usr/share/zoneinfo/Region/City /etc/localtime | ||
+ | </code> | ||
Set clock to localtime for Windows dualboot | Set clock to localtime for Windows dualboot | ||
+ | <code> | ||
hwclock --systohc --localtime | hwclock --systohc --localtime | ||
+ | </code> | ||
- | Locale | + | ===== Locale ===== |
uncomment en_US.UTF-8 in /etc/locale.gen | uncomment en_US.UTF-8 in /etc/locale.gen | ||
create /etc/locale.conf | create /etc/locale.conf | ||
Line 59: | Line 63: | ||
LANG=en_US.UTF-8 | LANG=en_US.UTF-8 | ||
</file> | </file> | ||
- | Genereate Locale | ||
- | locale-gen | ||
- | Hostname from DHCP | + | ===== Genereate Locale ===== |
- | append | + | <code>locale-gen</code> |
- | env force_hostname=YES to /etc/dhcpcd.conf | + | |
- | Auto DHCP on boot | + | ===== Hostname from DHCP ===== |
+ | append to /etc/dhcpcd.conf | ||
+ | <code> | ||
+ | env force_hostname=YES | ||
+ | </code> | ||
+ | |||
+ | ===== Auto DHCP on boot ===== | ||
create /etc/netctl/lan | create /etc/netctl/lan | ||
<file|/etc/netctl/lan> | <file|/etc/netctl/lan> | ||
Line 78: | Line 85: | ||
</code> | </code> | ||
- | Hosts file | + | ===== Hosts file ===== |
<file|/etc/hosts> | <file|/etc/hosts> | ||
127.0.0.1 localhost | 127.0.0.1 localhost | ||
Line 84: | Line 91: | ||
</file> | </file> | ||
- | Create acmadmin | + | ===== Create acmadmin ===== |
<code> | <code> | ||
useradd -d /opt/acmadmin -m -G wheel acmadmin | useradd -d /opt/acmadmin -m -G wheel acmadmin | ||
Line 90: | Line 97: | ||
</code> | </code> | ||
- | Sudo access to wheel | + | ===== Sudo access to wheel ===== |
/etc/sudoers | /etc/sudoers | ||
uncomment this line | uncomment this line | ||
Line 97: | Line 104: | ||
</code> | </code> | ||
- | Install bootloader | + | ===== Pacman conf ===== |
+ | /etc/pacman.conf | ||
+ | uncomment the lines | ||
+ | <code> | ||
+ | [multilib] | ||
+ | Include = /etc/pacman.d/mirrorlist | ||
+ | </code> | ||
+ | add acm repo | ||
+ | <code> | ||
+ | [uicacm] | ||
+ | SigLevel = Optional TrustAll | ||
+ | Server = http://mozart.acm.cs/acm-packages/archlinux/ | ||
+ | </code> | ||
+ | <code> | ||
+ | pacman -Sy | ||
+ | </code> | ||
+ | |||
+ | ===== Install bootloader ===== | ||
<code> | <code> | ||
mkinitcpio -p linux | mkinitcpio -p linux | ||
- | pacman -S grub ntfs-3g os-prober | + | pacman -S grub ntfs-3g os-prober intel-ucode |
grub-install /dev/sdx | grub-install /dev/sdx | ||
grub-mkconfig -o /boot/grub/grub.cfg | grub-mkconfig -o /boot/grub/grub.cfg | ||
</code> | </code> | ||
- | Reboot | + | ===== Reboot ===== |
<code> | <code> | ||
exit | exit | ||
Line 112: | Line 136: | ||
</code> | </code> | ||
- | Install openssh | + | ===== Install openssh ===== |
<code> | <code> | ||
sudo pacman -S openssh | sudo pacman -S openssh | ||
sudo systemctl enable sshd | sudo systemctl enable sshd | ||
</code> | </code> | ||
+ | |||
+ | ===== Create acmguest user ===== | ||
+ | <code> | ||
+ | sudo useradd -m -d /opt/acmguest acmguest | ||
+ | sudo passwd acmguest | ||
+ | </code> | ||
+ | <file|/etc/sudoers.d/acmguset-sudo> | ||
+ | acmguest ALL=(root) NOPASSWD: /usr/bin/guestd | ||
+ | </file> | ||
+ | |||
+ | ===== LDAP Setup ===== | ||
+ | [[linux:arch_ad_backend]] | ||
+ | ===== mount home dir ===== | ||
+ | Install nfs-utils | ||
+ | <code> | ||
+ | sudo pacman -S nfs-utils | ||
+ | </code> | ||
+ | <file|/etc/fstab> | ||
+ | . | ||
+ | . | ||
+ | 172.29.0.6:/acm-home /home nfs noauto,x-systemd.automount,x-systemd.device-timeout=10,timeo=14,x-systemd.idle-timeout=1min 0 0 | ||
+ | 172.29.0.7:/pkgs-64 /var/cache/pacman/pkg nfs noauto,x-systemd.automount,x-systemd.device-timeout=10,timeo=14,x-systemd.idle-timeout=1min 0 0 | ||
+ | </file> |