Skip to content

Commit

Permalink
chore: removed alt_dns;
Browse files Browse the repository at this point in the history
fix: fail to configure bootloader when efi partition is set to /boot/efi;
  • Loading branch information
helmuthdu committed May 6, 2018
1 parent 2277eb4 commit eb1aba7
Show file tree
Hide file tree
Showing 4 changed files with 48 additions and 86 deletions.
73 changes: 16 additions & 57 deletions fifo
Original file line number Diff line number Diff line change
Expand Up @@ -109,46 +109,6 @@ configure_mirrorlist(){
$EDITOR /etc/pacman.d/mirrorlist
}
#}}}
#SETUP ALTERNATIVE DNS {{{
setup_alt_dns(){
cat <<- EOF > /etc/resolv.conf.head
# OpenDNS IPv4 nameservers
nameserver 208.67.222.222
nameserver 208.67.220.220
# OpenDNS IPv6 nameservers
nameserver 2620:0:ccc::2
nameserver 2620:0:ccd::2
# Google IPv4 nameservers
nameserver 8.8.8.8
nameserver 8.8.4.4
# Google IPv6 nameservers
nameserver 2001:4860:4860::8888
nameserver 2001:4860:4860::8844
# Comodo nameservers
nameserver 8.26.56.26
nameserver 8.20.247.20
# Basic Yandex.DNS - Quick and reliable DNS
nameserver 77.88.8.8
nameserver 77.88.8.1
# Safe Yandex.DNS - Protection from virus and fraudulent content
nameserver 77.88.8.88
nameserver 77.88.8.2
# Family Yandex.DNS - Without adult content
nameserver 77.88.8.7
nameserver 77.88.8.3
# censurfridns.dk IPv4 nameservers
nameserver 91.239.100.100
nameserver 89.233.43.71
# censurfridns.dk IPv6 nameservers
nameserver 2001:67c:28a4::
nameserver 2002:d596:2a92:1:71:53::
EOF
}
#}}}
#UMOUNT PARTITIONS {{{
umount_partitions(){
mounted_partitions=(`lsblk | grep ${MOUNTPOINT} | awk '{print $7}' | sort -r`)
Expand Down Expand Up @@ -526,7 +486,7 @@ install_base_system(){
print_info "Using the pacstrap script we install the base system. The base-devel package group will be installed also."
rm ${MOUNTPOINT}${EFI_MOUNTPOINT}/vmlinuz-linux
select_linux_version
pacstrap ${MOUNTPOINT} base-devel parted btrfs-progs f2fs-tools ntp net-tools
pacstrap ${MOUNTPOINT} base-devel parted btrfs-progs f2fs-tools net-tools
[[ $? -ne 0 ]] && error_msg "Installing base system to ${MOUNTPOINT} failed. Check error messages above."
local PTABLE=`parted -l | grep "gpt"`
[[ -n $PTABLE ]] && pacstrap ${MOUNTPOINT} gptfdisk
Expand Down Expand Up @@ -759,29 +719,29 @@ configure_bootloader(){
1)
arch_chroot "syslinux-install_update -iam"
if [[ $LUKS -eq 1 ]]; then
sed -i "s/APPEND root=.*/APPEND root=\/dev\/mapper\/${ROOT_PART} cryptdevice=\/dev\/${LUKS_DISK}:crypt ro/g" ${MOUNTPOINT}/boot/syslinux/syslinux.cfg
sed -i "s/APPEND root=.*/APPEND root=\/dev\/mapper\/${ROOT_PART} cryptdevice=\/dev\/${LUKS_DISK}:crypt ro/g" ${MOUNTPOINT}${EFI_MOUNTPOINT}/syslinux/syslinux.cfg
elif [[ $LVM -eq 1 ]]; then
sed -i "s/sda[0-9]/\/dev\/mapper\/${ROOT_PART}/g" ${MOUNTPOINT}/boot/syslinux/syslinux.cfg
sed -i "s/sda[0-9]/\/dev\/mapper\/${ROOT_PART}/g" ${MOUNTPOINT}${EFI_MOUNTPOINT}/syslinux/syslinux.cfg
else
sed -i "s/sda[0-9]/${ROOT_PART}/g" ${MOUNTPOINT}/boot/syslinux/syslinux.cfg
sed -i "s/sda[0-9]/${ROOT_PART}/g" ${MOUNTPOINT}${EFI_MOUNTPOINT}/syslinux/syslinux.cfg
fi
print_warning "The partition in question needs to be whatever you have as / (root), not /boot."
pause_function
$EDITOR ${MOUNTPOINT}/boot/syslinux/syslinux.cfg
$EDITOR ${MOUNTPOINT}${EFI_MOUNTPOINT}/syslinux/syslinux.cfg
break
;;
2)
arch_chroot "syslinux-install_update -i"
if [[ $LUKS -eq 1 ]]; then
sed -i "s/APPEND root=.*/APPEND root=\/dev\/mapper\/${ROOT_PART} cryptdevice=\/dev\/${LUKS_DISK}:crypt ro/g" ${MOUNTPOINT}/boot/syslinux/syslinux.cfg
sed -i "s/APPEND root=.*/APPEND root=\/dev\/mapper\/${ROOT_PART} cryptdevice=\/dev\/${LUKS_DISK}:crypt ro/g" ${MOUNTPOINT}${EFI_MOUNTPOINT}/syslinux/syslinux.cfg
elif [[ $LVM -eq 1 ]]; then
sed -i "s/sda[0-9]/\/dev\/mapper\/${ROOT_PART}/g" ${MOUNTPOINT}/boot/syslinux/syslinux.cfg
sed -i "s/sda[0-9]/\/dev\/mapper\/${ROOT_PART}/g" ${MOUNTPOINT}${EFI_MOUNTPOINT}/syslinux/syslinux.cfg
else
sed -i "s/sda[0-9]/${ROOT_PART}/g" ${MOUNTPOINT}/boot/syslinux/syslinux.cfg
sed -i "s/sda[0-9]/${ROOT_PART}/g" ${MOUNTPOINT}${EFI_MOUNTPOINT}/syslinux/syslinux.cfg
fi
print_warning "The partition in question needs to be whatever you have as / (root), not /boot."
pause_function
$EDITOR ${MOUNTPOINT}/boot/syslinux/syslinux.cfg
$EDITOR ${MOUNTPOINT}${EFI_MOUNTPOINT}/syslinux/syslinux.cfg
break
;;
3)
Expand Down Expand Up @@ -811,16 +771,16 @@ configure_bootloader(){
print_warning "Please check your .conf file"
partuuid=`blkid -s PARTUUID ${ROOT_MOUNTPOINT} | awk '{print $2}' | sed 's/"//g' | sed 's/^.*=//'`
if [[ $LUKS -eq 1 ]]; then
echo -e "title\tArch Linux\nlinux\t/vmlinuz-linux\ninitrd\t/initramfs-linux.img\noptions\tcryptdevice=\/dev\/${LUKS_DISK}:luks root=\/dev\/mapper\/${ROOT_PART} rw" > ${MOUNTPOINT}/boot/loader/entries/arch.conf
echo -e "title\tArch Linux\nlinux\t/vmlinuz-linux\ninitrd\t/initramfs-linux.img\noptions\tcryptdevice=\/dev\/${LUKS_DISK}:luks root=\/dev\/mapper\/${ROOT_PART} rw" > ${MOUNTPOINT}${EFI_MOUNTPOINT}/loader/entries/arch.conf
elif [[ $LVM -eq 1 ]]; then
echo -e "title\tArch Linux\nlinux\t/vmlinuz-linux\ninitrd\t/initramfs-linux.img\noptions\troot=\/dev\/mapper\/${ROOT_PART} rw" > ${MOUNTPOINT}/boot/loader/entries/arch.conf
echo -e "title\tArch Linux\nlinux\t/vmlinuz-linux\ninitrd\t/initramfs-linux.img\noptions\troot=\/dev\/mapper\/${ROOT_PART} rw" > ${MOUNTPOINT}${EFI_MOUNTPOINT}/loader/entries/arch.conf
else
echo -e "title\tArch Linux\nlinux\t/vmlinuz-linux\ninitrd\t/initramfs-linux.img\noptions\troot=PARTUUID=${partuuid} rw" > ${MOUNTPOINT}/boot/loader/entries/arch.conf
echo -e "title\tArch Linux\nlinux\t/vmlinuz-linux\ninitrd\t/initramfs-linux.img\noptions\troot=PARTUUID=${partuuid} rw" > ${MOUNTPOINT}${EFI_MOUNTPOINT}/loader/entries/arch.conf
fi
echo -e "default arch\ntimeout 5" > ${MOUNTPOINT}/boot/loader/loader.conf
echo -e "default arch\ntimeout 5" > ${MOUNTPOINT}${EFI_MOUNTPOINT}/loader/loader.conf
pause_function
$EDITOR ${MOUNTPOINT}/boot/loader/entries/arch.conf
$EDITOR ${MOUNTPOINT}/boot/loader/loader.conf
$EDITOR ${MOUNTPOINT}${EFI_MOUNTPOINT}/loader/entries/arch.conf
$EDITOR ${MOUNTPOINT}${EFI_MOUNTPOINT}/loader/loader.conf
break
;;
2)
Expand All @@ -844,7 +804,7 @@ configure_bootloader(){
case "$REPLY" in
1)
arch_chroot "refind-install"
$EDITOR ${MOUNTPOINT}/boot/refind_linux.conf
$EDITOR ${MOUNTPOINT}${EFI_MOUNTPOINT}/refind_linux.conf
break
;;
2)
Expand Down Expand Up @@ -934,7 +894,6 @@ do
5)
install_base_system
configure_keymap
setup_alt_dns
checklist[5]=1
;;
6)
Expand Down
56 changes: 29 additions & 27 deletions lilo
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,7 @@ install_basic_setup(){
print_title "AVAHI - https://wiki.archlinux.org/index.php/Avahi"
print_info "Avahi is a free Zero Configuration Networking (Zeroconf) implementation, including a system for multicast DNS/DNS-SD discovery. It allows programs to publish and discovers services and hosts running on a local network with no specific configuration."
package_install "avahi nss-mdns"
is_package_installed "avahi" && system_ctl enable avahi-daemon
is_package_installed "avahi" && system_ctl enable avahi-daemon.service
pause_function
print_title "ALSA - https://wiki.archlinux.org/index.php/Alsa"
print_info "The Advanced Linux Sound Architecture (ALSA) is a Linux kernel component intended to replace the original Open Sound System (OSSv3) for providing device drivers for sound cards."
Expand Down Expand Up @@ -576,8 +576,8 @@ install_samba(){
pdbedit -a -u ${username}
done
# enable services
system_ctl enable smbd
system_ctl enable nmbd
system_ctl enable smb.service
system_ctl enable nmb.service
pause_function
fi
}
Expand Down Expand Up @@ -613,9 +613,10 @@ install_tlp(){
read_input_text "Install TLP" $TLP
if [[ $OPTION == y ]]; then
package_install "tlp"
system_ctl enable tlp
system_ctl enable tlp-sleep
system_ctl disable systemd-rfkill
system_ctl enable tlp.service
system_ctl enable tlp-sleep.service
system_ctl mask systemd-rfkill.service
system_ctl mask systemd-rfkill.socket
tlp start
pause_function
fi
Expand All @@ -626,21 +627,26 @@ install_xorg(){
print_title "XORG - https://wiki.archlinux.org/index.php/Xorg"
print_info "Xorg is the public, open-source implementation of the X window system version 11."
echo "Installing X-Server (req. for Desktopenvironment, GPU Drivers, Keyboardlayout,...)"
package_install "xorg-server xorg-apps xorg-server-xwayland xorg-xinit xorg-xkill xorg-xinput xf86-input-libinput"
package_install "xorg-server xorg-apps xorg-xinit xorg-xkill xorg-xinput xf86-input-libinput"
package_install "mesa"
modprobe uinput
pause_function
}
#}}}
#WAYLAND {{{
install_wayland(){
print_title "WAYLAND - https://wiki.archlinux.org/index.php/Wayland"
print_info "Wayland is a protocol for a compositing window manager to talk to its clients, as well as a library implementing the protocol. "
package_install "weston xorg-server-xwayland"
pause_function
}
#}}}
#FONT CONFIGURATION {{{
font_config(){
print_title "FONTS CONFIGURATION - https://wiki.archlinux.org/index.php/Font_Configuration"
print_info "Fontconfig is a library designed to provide a list of available fonts to applications, and also for configuration for how fonts get rendered."
read_input_text "Install Fontconfig" $FONTCONFIG
if [[ $OPTION == y ]]; then
pacman -S --asdeps --needed cairo fontconfig freetype2
pause_function
fi
pacman -S --asdeps --needed cairo fontconfig freetype2
pause_function
}
#}}}
#VIDEO CARDS {{{
Expand Down Expand Up @@ -855,7 +861,7 @@ install_desktop_environment(){
do
print_title "GNOME ICONS"
echo " 1) $(menu_item "numix-icon-theme-git") $AUR"
echo " 2) $(menu_item "arc-icon-theme")"
echo " 2) $(menu_item "papirus-icon-theme-git")"
echo ""
echo " b) BACK"
echo ""
Expand All @@ -867,8 +873,7 @@ install_desktop_environment(){
aur_package_install "numix-icon-theme-git numix-circle-icon-theme-git"
;;
2)
aur_package_install "moka-icon-theme-git"
package_install "arc-icon-theme"
package_install "papirus-icon-theme-git"
;;
"b")
break
Expand Down Expand Up @@ -1397,15 +1402,12 @@ install_nm_wicd(){
1)
print_title "NETWORKMANAGER - https://wiki.archlinux.org/index.php/Networkmanager"
print_info "NetworkManager is a program for providing detection and configuration for systems to automatically connect to network. NetworkManager's functionality can be useful for both wireless and wired networks."
package_install "networkmanager dnsmasq networkmanager-openconnect networkmanager-openvpn networkmanager-pptp networkmanager-vpnc"
if [[ ${KDE} -eq 1 ]]; then
package_install "networkmanager dnsmasq plasma-nm networkmanager-qt"
else
package_install "networkmanager dnsmasq network-manager-applet nm-connection-editor gnome-keyring"
package_install "plasma-nm"
elif [[ ${GNOME} -eq 0 ]]; then
package_install "network-manager-applet nm-connection-editor gnome-keyring"
fi
# vpn support
package_install "networkmanager-openconnect networkmanager-openvpn networkmanager-pptp networkmanager-vpnc"
# power manager support
is_package_installed "tlp" && package_install "tlp-rdw"
# network management daemon
system_ctl enable NetworkManager.service
pause_function
Expand All @@ -1420,15 +1422,15 @@ install_nm_wicd(){
package_install "wicd wicd-gtk"
fi
# WICD daemon
system_ctl enable wicd
system_ctl enable wicd.service
pause_function
;;
3)
print_title "CONNMAN - https://wiki.archlinux.org/index.php/Connman"
print_info "ConnMan is an alternative to NetworkManager and Wicd and was created by Intel and the Moblin project for use with embedded devices."
package_install "connman"
# ConnMan daemon
system_ctl enable connman
system_ctl enable connman.service
pause_function
;;
esac
Expand Down Expand Up @@ -2470,7 +2472,6 @@ install_video_apps(){
;;
8)
package_install "vlc"
[[ ${KDE} -eq 1 ]] && package_install "phonon-qt5-vlc"
;;
9)
package_install "kodi"
Expand Down Expand Up @@ -2823,7 +2824,7 @@ install_fonts(){
choose_ime_m17n(){
while true
do
print_title "M17n based IME - Input scripts (such as the Indic ones) using m17n maps - https://wiki.archlinux.org/index.php/Internationalization"
print_title "INTERNATIONALIZATION - https://wiki.archlinux.org/index.php/Internationalization"
echo " 1) $(menu_item "fcitx")"
echo " 2) $(menu_item "ibus")"
echo ""
Expand Down Expand Up @@ -2988,7 +2989,7 @@ do
echo "11) $(mainmenu_item "${checklist[11]}" "Games")"
echo "12) $(mainmenu_item "${checklist[12]}" "Web server")"
echo "13) $(mainmenu_item "${checklist[13]}" "Fonts")"
echo "14) $(mainmenu_item "${checklist[14]}" "International script input: M17n based IME")"
echo "14) $(mainmenu_item "${checklist[14]}" "Internationalization")"
echo "15) $(mainmenu_item "${checklist[15]}" "Extra")"
echo "16) $(mainmenu_item "${checklist[16]}" "Clean Orphan Packages")"
echo "17) $(mainmenu_item "${checklist[17]}" "Reconfigure System")"
Expand All @@ -3011,6 +3012,7 @@ do
install_zram
install_video_cards
install_xorg
install_wayland
font_config
install_cups
install_additional_firmwares
Expand Down
3 changes: 2 additions & 1 deletion lilo.automode
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,8 @@
THEMES_OPTIONS="1 2"
#ICONS THEMES {{{
# 1) Numix
ICONS_THEMES="1"
# 2) Papirus
ICONS_THEMES="2"
#}}}
#GTK THEMES {{{
# 1) Arc
Expand Down
2 changes: 1 addition & 1 deletion sharedfuncs
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
KDE=0
#}}}
# MOUNTPOINTS {{{
EFI_MOUNTPOINT="/boot/efi"
EFI_MOUNTPOINT="/boot"
ROOT_MOUNTPOINT="/dev/sda1"
BOOT_MOUNTPOINT="/dev/sda"
MOUNTPOINT="/mnt"
Expand Down

0 comments on commit eb1aba7

Please sign in to comment.