I have an Manjaro server running for 3+ years now.
Why Manjaro ?
Because it's not as bleeding edge as Arch. They test more before releasing packages.
Why not just use Debian or Ubuntu or "Other Distro" Server ?
IMHO: Because AUR + pacman are just great to work with, no big bang every few years, latest updates and it's my Home Server.
I have nothing against any other distro's, it's just a personal preference, get over it !Bleeding edge server !?Tame it ? I use Manjaro for that reason and i run the LTS kernel. Have had no problems.
Be sure to check before installing from the AUR, because Arch is ahead of Manjaro.
That could lead to a dependancy not being available yet in Manjaro, because it's still being checked.
I am preparing for a new server and wanted to check if everything still works, before i start installing.
Might as wel document it on my website to.
Minimalistic Headless CLI Install Manjaro
Architect isn't available anymore (it is but has trouble, but you could make an architect iso yourself)
For me it's the Arch way then.
So i build an Minimalistic Headless Manjaro server from the CLI.
Start a Manjaro distro of your flavour
Set the Boot settings like "Time Zone" and "Keyboard" and then select "Boot with open source drivers".
In the GUI
Make sure the date, time and timezone are set right, else set and sync them before starting.
Press 'ctrl+alt+F4' to go to the CLI
Login to the Manjaro CLI
Now elevate yourself so you don't have to sudo all the time
Let's start by partitioning the disk
List all disks
To check which disk is which.
Just check if you are in efi mode
If this folder can not be found, you are not running your bios in uefi mode
Use cfdisk to partition your drive
Use the --zero argument to empty the whole partition table
cfdisk --zero /dev/sda
Select label type "gpt" when prompted and press enter
EFI or $esp
Select Free space
Select EFI System
Select Free space
Enter to assign the remaining space to the ROOT
Select Linux root (x86_64)
Save the changes
Input yes, not just y, when prompted
EFI ($esp)Format the EFI partition (1) with the FAT32 filesystem
mkfs.fat -F 32 /dev/sda1
RootFormat the ROOT partition (2) with the EXT4 filesystem
Before we install the base system we need to mount the devices. First we mount the root system - using the folder /mnt for the temporary mount, then we make a folder for /boot/efi.
mount /dev/sda2 /mnt
mkdir -p /mnt/boot/efi
Verify your folder structure
find /mnt -type d
Now Mount the efi partition
mount /dev/sda1 /mnt/boot/efi
Verify your mounts
Before we install anything let's set our mirrors.
Set pacman mirrors
We use pacman-mirrors to set pacman to:
pacman-mirrors -c Country
Download the databases and install keyrings
pacman -Syy archlinux-keyring manjaro-keyring
Create trust Database
Create trust database, populate and refresh keys
First check which kernel you want to install
To see which linux kernels are available:
To check the available kernels through the CLI (for the naming schema):
To install the Base:
First let look at the arch wiki and the manjaro post:
The Arch wiki says:
pacstrap -K /mnt base linux linux-firmware
But the Arch wiki also states:
Installing other packages may be necessary for a fully functional base system. In particular, consider installing:
- userspace utilities for the management of file systems that will be used on the system,
- utilities for accessing RAID or LVM partitions,
- specific firmware for other devices not included in linux-firmware (e.g. sof-firmware for sound cards),
- software necessary for networking (e.g. a network manager or DHCP client),
- a text editor,
- packages for accessing documentation in man and info pages: man-db, man-pages and texinfo.
The Manjaro Guide says:
basestrap /mnt base $LINUX dhcpcd networkmanager grub mkinitcpio efibootmgr vi nano sudo links
Where $LINUX is the kernel of linux you want to install (linux515 for instance)
So the manjaro guide has added all the base packages.
But to have both dhcpcd and networkmanager installed is not recommend. NetworkManager is the better one so just install that.
Still there are some very important and/ or handy packages missing:base-devel - To build packages from the AUR
pamac-cli - To install packages from the AUR
linux515-headers - Some driver installs asks for headers
manjaro-release - Gives the lsb_release command, which is used by a lot of software.
mhwd - Manjaro Linux Hardware Detection library and application
mhwd-db - Manjaro Linux Hardware Detection Database
mhwd-amdgpu - MHWD module-ids for amdgpu
mhwd-nvidia - MHWD module-ids for nvidia
linux-firmware - Base firmware package
amd-ucode - For AMD processors
intel-ucode - For INTEL processors
ntfs-3g - NTFS support
dosfstools - FAT support
exfatutils - exFAT utilities
f2fs-tools - f2fs tools needed to make a f2fs
btrfs-progs - btrfs support (needed if you run btrfs)
linux515-zfs - zfs support (needed if you run zfs)
samba- Windows File Sharing (smb) support
nfs-utils - nfs (Network File System) support
tar - To handle tar.gz files
unzip - To un-zip files
p7zip - For 7Z files
curl - File transfer server
git - To download from github
man-db - To read manuals with the man command
openssh - To remote connect to the machine
grub-theme-manjaro - Manjaro's Grub Theme (Just for fun)
# AMD Videocard
mhwd -a pci free 0300
# NVIDIA Videocard
mhwd -a pci nonfree 0300
first generate an fstab file (In Arch the command = genfstab, in Manjaro the command = fstabgen)
This mounts all your disks.
fstabgen -U /mnt >> /mnt/etc/fstab
Then edit fstab and replace all "relatime" with "noatime"
vi and nano are text editors.
To save the file from "vi" type ':wq' (: = Open Command Mode, w = Write, q = quit)To save the file from "nano" use "ctrl+o" (write-out) and hit "enter", then "ctrl+x" (Exit) to exit
Next thing is to configure the system in a chrooted environment, using bash as shell.
chroot changes the root directory for the current running processes and children.
manjaro-chroot /mnt /bin/bash
Set Console keyboardSet your keyboard layout
I use a dutch locale, but we use a US-Int keyboard layout in the Netherlands.
Set your keyboard layout
This set's the time and date format settings
Uncomment the locale you want to use
Remove the comment (#) for the locale(s) to be generated (UTF-8 is the recommended choice)
TIP: Uncomment the locale 'en_US.UTF-8 UTF-8' as a fallback locale.
English (United States):
English (United Kingdom):
Generate the messages
Make a locale configuration
Make a locale configuration in /etc/locale.conf
Add the LANG that you want for messages
Set TimezoneSet the time zone for your location using the Continent/Capitol format. Look in /usr/share/zoneinfo/ for format.
Symlink the time zone as /etc/localtime - example for the Netherlands
NetworkManagerEnable the NetworkManager to have it start at boot
systemctl enable NetworkManager
After install i could only reach my server on ip not on server name, this was because systemd-resolved service wasn't running
Enable systemd-resolved to have it start at boot
systemctl enable systemd-resolved
Time syncronizationEnable the Time Daemon to have it start at boot
systemctl enable systemd-timesyncd
SSH Remote ConnectionEnable the ssh daemon to have it start at boot
systemctl enable sshd
System administrationAllow members of the wheel group to perform administrative tasks.
I'm using nano to edit visudo
Locate the line reading # %wheel ALL=(ALL:ALL) ALL and remove the # in the beginning of the line
To save the file from "vi" type ':wq' (: = Open Command Mode, w = Write, q = quit)
To save the file from "nano" use ctrl+o an hit enter, then ctrl+x to exit
%wheel ALL=(ALL:ALL) ALL
Root passwordSet a password the root user
Add a user for yourselfAdd a user called 'yourself' (Change to your desired username)
useradd -m -G wheel -s /bin/bash yourself
Set password for yourselfSet a password for the user 'yourself' (Change to your desired username)
Now to make initramfs (Root Filesystem Image) and make our grub bootloader
InitramfsBuild the initramfs
Just some finishing touches and we good.
This next one is just for fun.
Change pacman to color and make pacman eat pills in terminal
sudo nano /etc/pacman.conf
Uncomment color and add ILoveCandy under # Misc options
Now to activate AUR (Arch Universal Repository) support
Always double check when installing packages from the AUR because Arch is ahead of Manjaro's release schema.
Activate AUR support and AUR updates for pamac
sudo nano /etc/pamac.conf
and uncomment the following 2 lines
## Allow Pamac to search and install packages from AUR:
## When AUR support is enabled check for updates from AUR:
Close chrootClose the chroot enviroment
Unmount the partitionsUnmount the partitions mounted on /mnt
umount -R /mnt
Shutdown your systemRemember to remove your install media
Now turn on your server and see if it boots. If it works, your greeted with an command line.
Login with your username and password to see if that works to.
Now test the following to see if you have internet.
If this works, your system is ready to go.
You can also test if you can ssh to your system from another machine now. Use it's HostName and/ or ip adress.
Samba and zfs-utils need to be setup if you want to use them, but you have to config them before starting the service. That's why i didn't enable them yet.