Site icon DesignLinux

How to Install FreeBSD 13.0 with Static Network IP Address

FreeBSD is a Free Unix-like operating system from Berkeley Software distribution, which is available for all major platforms x86_64, IA-32, PowerPC, ARM, etc, and mainly focuses on features, speed, and performance stability.

FreeBSD used by many top-level IT companies like Juniper Networks, NetApp, Nokia, IBM, etc., and available for server platforms with a command-line interface only, but we can use any other Linux Desktop environment such as Xfce, KDE, GNOME, etc. to make it user-friendly distro.

My Environment Setup
IP Address	:	192.168.0.142
Hostname	:	freebsd.tecmintlocal.com
Hard Disk	:	16GB
Memory		:	2GB

This article will walk you through the brief instructions on installing FreeBSD 13.0 and configure network (setting static IP address) interfaces using a text-based installation utility named bsdinstall under i386 and AMD64 architectures.

Installation of FreeBSD 13.0

1. First go to the official FreeBSD site, and download the FreeBSD installer for your architecture, the installer comes in a variety of different formats including CD, DVD, Network Install, USB images, as well as Virtual Machine images.

2. After downloading the FreeBSD installer image, burn it to the media (CD/DVD or USB), and boot the system with inserted media. After the system boots with the installation media, the following menu will be displayed.

FreeBSD Boot Menu

3. By default, the menu will wait for 10 seconds for user input before it booting into the FreeBSD installer or we can press the ‘Backspace‘ key to continue the installation, and then press the ‘Enter‘ key to boot into FreeBSD. Once the boot is complete, a welcome menu displayed with the following options.

Choose Install FreeBSD

Press Enter to choose the default option ‘Install‘, or you can choose ‘Shell‘ to access command-line programs to prepare the disks before installation or select the ‘Live CD‘ option to try out FreeBSD before installing it. But, here we going to use the default option ‘Install‘ as we are installing FreeBSD.

4. Next, a list of keymaps shown, with the default selection of Keymap, just choose the default option to continue with the keymap setup.

FreeBSD Keymap Selection

5. Next, give a hostname for our system, I have used freebsd.tecmintlocal.com as my hostname.

Set Hostname

6. Choose the components to install for FreeBSD, by default every option is preselected.

Select Components to Install on FreeBSD

7. In this step, we need to partition the Disk for our installation. Here you will have four options:

But, here we going to choose the ‘Manual‘ option to create partitions as per our needs.

FreeBSD Manual Disk Partitioning

8. After selecting ‘Manual Partitioning‘, a partition editor opens with highlighted drive ‘ad0‘ and choose to Create for Creating a valid partition scheme.

Choose FreeBSD Disk Partition

9. Next, choose GPT to create a Partition table. GPT is usually the most selected method for amd64 computers. Older computers, which are not compatible with GPT should use MBR.

Select GPT Partition
GPT Partition Created

10. After creating the Partition table, now you can see that our Disk was changed to a GPT partition table, Choose ‘Create‘ to define the partitions.

FreeBSD GPT Partition Schema

11. Now, here we need to define three Partitions for /boot, Swap, /. I’m going to define my partition size as follows.

Choose ‘Create‘ and define the partitions one by one, at first boot ‘Type‘ needs to be ‘freebsd-boot‘ and size here I have used 512K and press OK to create the next Partition Swap.

Create Boot Partition

Choose ‘Create‘ and define swap partition for 1 GB and Press OK.

Create Swap Partition

Then again Choose ‘Create‘ and define / partition. Now use the remaining size for / partition. Use Type as freebsd-ufs and mount point as /.

Create Root Partition

12. After creating all partitions we will get the below layout. Choose ‘Finish‘ to move forward for the next step for installation.

FreeBSD Disk Partition Layout

13. Once the disks are created, the next window provides the last chance to edit changes before the selected disk(s) are formatted. If you wish to make a change, select [ Back ] to go back to the main partitioning menu or select [ Revert & Exit ] to exit the installer without modifying any changes to the disk. But, here we need to select ‘Commit‘ to start the installation and press ‘Enter‘.

Partition Formatting

14. Once the installer formats all selected disks, then it initializes the partitions to download and verify all the selected components, and then downloaded components are extracted to the disk..as shown in the picture below.

FreeBSD Archive Extraction

15. Once all requested distribution packages have been extracted to the disk, the next window displays the first post-installation configuration screen. Here, first, you need to set the ‘root‘ password for our FreeBSD server.

Set Root Password

Configuring Network Interface on FreeBSD

16. Next, a list of available network interfaces are displayed on the screen, select the interface to configure. Here I have only one network adapter. If you have multiple network adapters choose the adapter which you need to use.

Configure Network Interfaces

17. Next, select whether or not an IPv4 address should be defined on the selected Ethernet interface. Here we’ve 2 options to configure the network interface, one is using DHCP which will automatically assign an IP address to our network interface, second defining IP address manually. But, here we are assigning a static IP address to the computer as shown below.

Network Configuration
Set IP Address in FreeBSD

18. Next, enter a valid DNS server IP in IPv4 DNS #1 and #2 and Press OK to continue.

Set DNS Servers in FreeBSD

19. The next option prompt you to check the system clock uses UTC or local time, if you have doubt, just select ‘No‘ to select the more commonly used local time.

Select System Clock

20. The next windows ask you to set the correct local time and time zone.

Select Timezone in FreeBSD
Select Country Region

21. Next, select the services that you want to start at system boots.

Enabling Services

22. The next option, ask you to create at least one user account to login into the system as a non-root account to keep the system more safe and secure. Select [ Yes ] to add new users.

Add New User

Follow the prompts and enter the requested information for the user account (example user ‘tecmint‘) as shown in the picture below.

User Information

After entering the user information above, a summary is shown for review. If any mistake was made during user creation, enter no and try again. If everything is entered correctly, enter yes to create the new user.

User Confirmation

23. After configured everything above, a final chance is given to modify or change settings. After any final configuration is complete, select Exit.

Final Configuration

24. After installation is completed, select ‘Reboot‘ reboot the system, and start using your new FreeBSD system.

Installation Completed

25. After the reboot completes we will get the Terminal to log in for an account, By default, we will have root and tecmint which we have created during installation. Login to root account and check for system information such as IP Address, host-name, file system disk space, and release version.

# hostname
# ifconfig | grep inet
# uname -mrs // To get the Installed FreeBSD release version.
# df -h // Disk space check.
System Information
Conclusion

In this article we have seen, how we’ve installed and configured FreeBSD, in my next upcoming article, we will see how to install and configure packages in FreeBSD. If you’ve any queries about installation, feel free to drop your valuable comments below.

Exit mobile version