2014년 4월 29일 화요일

freebsd 시스템 튠닝 관련 명령

freebsd 시스템 튠닝 관련 명령

프비 비프음 끄기

# sysctl hw.syscons.bell=0

Make sure settings remains same after you reboot the laptop, enter:
 
# echo "hw.syscons.bell=0" >> /etc/sysctl.conf

Test it:
 
# reboot

FreeBSD 네트웍 재시작 방법

FreeBSD 네트웍 재시작 방법 

To start FreeBSD network service:
# /etc/rc.d/netif start
To stop FreeBSD network service:
# /etc/rc.d/netif stop
To restart FreeBSD network service:
# /etc/rc.d/netif restart

Manual method using ifconfig

To stop network card (NIC) on-fly:
# ifconfig network-interface down
To start network card (NIC) on fly:
# ifconfig network-interface up
To list down network interface:
# ifconfig -d
To list up network interface:
# ifconfig -u

FreeBSD Update / restart routing tables / service

It is also necessary to update routing table after restating networking service, enter:
# /etc/rc.d/routing restart

How do I restart network service over ssh session?

You need to type the commands as follows in order to avoid any problems:
# /etc/rc.d/netif restart && /etc/rc.d/routing restart

FreeBSD 4.x and prior version only - start, restart, stop network service

1) To start network service under FreeBSD you need to copy special
script as follows:
# cp /usr/share/examples/etc/netstart /etc/network
2) Execute script:
. /etc/network
OR
sh /etc/network
Please note that script will do all necessary work for you i.e. it will start network, routing, firewall etc.