Archive for January, 2012

(Russian) fsck – проверка файловой системы

Sorry, this entry is only available in Russian.

FreeBSD kernel rebuilding (buildkernel)

Sorry, this entry is only available in Russian.

VI editor commands reference

vi (visual) — a range of the text editors created for the Unix operating system.

Read the rest of this entry »

What to do if the system does not boot, or you messed up important configuration files? A small FAQ on FreeBSD recovery

How to boot in single mode?

During booting, in the boot menu, choose Single mode – with figure 4

If there is no boot, before you reboot, press the space bar and enter “boot -s
Read the rest of this entry »

FreeBSD is installed — what’s next?

In the previous article “FreeBSD Installation step by step (with screenshots)” we’ve installed our OS FreeBSD. Now let’s make the initial settings.

After the installation and the first system reboot, we get to the login/password window. For the first time enter as rootuser, for which we created password during system istallation.

The purpose of this article is to describe the next steps:
1) Access – how to enter and work in network as a root user (sudo, default shell, text editor);
2) Network configuration (ifconfig, rc.conf, resolv.conf);
3) Ports update (cvsup);
4) System update (buildkernel and buildworld).
5) Defend everything precious for us with the help of firewall
6) Additional setting rc.conf – set up the console (rc.conf);
7) Installation of additional programs (make install);

Read the rest of this entry »

FreeBSD Installation step by step (with screenshots)


What is FreeBSD installation like? How difficult and unclear is this process?

About this and other issues is written in FreeBSD Manual (so called – Handbook) in a best way –

In general this handbook is recommended for anyone who wants to learn FreeBSD, and understand many aspects of its work, its concepts and programs used.

But, since I haven’t seen any system administrator who started learning of FreeBSD from reading Handbook. 🙂 And also knowing that many are too lazy to read manual and look for a necessary information, – I will describe a typical installation of FreeBSD, which I do myself. With screenshots and explanations of what and why I do.

Read the rest of this entry »

Update of the FreeBSD Ports Collection

Let’s review one of the way to update the FreeBSD ports collection.
I use cvsup program, which I install together with the system. But it’s not a problem if you didn’t do it.

Search it in ports –

cd /usr/ports/
/usr/ports]# whereis cvsup-without-gui
cvsup-without-gui: /usr/ports/net/cvsup-without-gui

Read the rest of this entry »

Installation of Samba on FreeBSD

Samba — this program, which allows access to network drives and printers with different operating systems to SMB/CIFS protocol. It has client and server parts. It is free software released under the GPL.

First of all, samba will allow to give access to some specify directories on the network. Using SMB protocol and password protection, you can copy necessary files, e.g. – for settings, system configuration or backups.

So, our task, – to make share to some directories, with password protection, with access only from certain IP-addresses or address ranges.
So said so done.

Read the rest of this entry »

Installation of web-server apache22+php52

Apache HTTP-server (from eng. a patchy server) — free web-server.
The system of Apache configuration is based on text configuration files. It has three nominal configuration levels:
– Server configuration (httpd.conf).
– Virtual host configuration (httpd.conf from version 2.2 extra/httpd-vhosts.conf).
– Directory-level configuration (.htaccess).

We will install apache22+php52

Part 1 – Installing of web-server Apache

Read the rest of this entry »

mac-address binding in FreeBSD

One time it became necessary to bind mac-addresses of clients’ PCs and other devices on the Gateway with FreeBSD.
It is not very difficult, but it is very inconvenient to do it manually. Let’s automate this process with Shell.


we have the network address range or (as an example)

we need to put automatically the static records into the file and to add them into the arp-table,  when a customer refers to the gateway, type 11:11:11:11:11:11 pub

pub makes the machine to be an ARP server,
even if PC, IP and mac of which are binded, is switched off
hacker can’t work in a network.

Scan the network and add all the responding addresses to the static arp-table

change this records “on the go” from file

Read the rest of this entry »