cd /usr/ports/shells/bash
make install clean; rehash
Меянем шелл заданному юзеру:
chsh -s /usr/local/bin/bash testuser
Источник: http://www.cyberciti.biz/faq/howto-set-bash-as-your-default-shell/
cd /usr/ports/shells/bash
make install clean; rehash
chsh -s /usr/local/bin/bash testuser
vi /etc/login.conf
:umask=002:
cap_mkdb /etc/login.conf
cd /usr/ports/www/nginx
make install clean
vi /etc/rc.conf
nginx_enable="YES"
/usr/local/etc/rc.d/nginx start
vi /boot/loader.conf
kern.cam.boot_delay=10000
zpool status
pool: backup
state: ONLINE
scrub: none requested
config:
NAME STATE READ WRITE CKSUM
backup ONLINE 0 0 0
raidz1 ONLINE 0 0 0
ad4 ONLINE 0 0 0
ad6 ONLINE 0 0 0
ad10 ONLINE 0 0 0
errors: No known data errors
zpool add backup cache ad14
cache A device used to cache storage pool data. A cache
device cannot be mirrored or part of a raidz or raidz2
configuration.For more information, see the "Cache Devices"
section.
zpool status
pool: backup
state: ONLINE
scrub: none requested
config:
NAME STATE READ WRITE CKSUM
backup ONLINE 0 0 0
raidz1 ONLINE 0 0 0
ad4 ONLINE 0 0 0
ad6 ONLINE 0 0 0
ad10 ONLINE 0 0 0
cache
ad14 ONLINE 0 0 0
errors: No known data errors
zpool status
pool: backup
state: ONLINE
scrub: none requested
config:
NAME STATE READ WRITE CKSUM
backup ONLINE 0 0 0
raidz1 ONLINE 0 0 0
ad4 ONLINE 0 0 0
ad6 ONLINE 0 0 0
ad10 ONLINE 0 0 0
logs ONLINE 0 0 0
ad14 ONLINE 0 0 0
errors: No known data errors
zpool remove backup ad14
cannot remove ad14: only inactive hot spares or cache devices can be removed
sysinstall
make search name=memcache -C /usr/ports
whereis memcached
memcached: /usr/ports/databases/memcached
cd /usr/ports/databases/memcached
make install clean
portinstall memcached
cd /usr/ports/www/apache22
make install clean
echo 'apache22_enable="YES"' >> /etc/rc.conf
/usr/local/etc/rc.d/apache22 start
service apache22 start
cd /usr/ports/lang/php5
make install clean
cd /usr/ports/lang/php5-extensions
make install clean
vi /usr/local/etc/apache22/httpd.conf
# возможно, эта строка уже будет добавлена, если она есть, повторно добавлять не нужно
LoadModule php5_module libexec/apache/libphp5.so
<IfModule mod_php5.c>
DirectoryIndex index.php index.html
</IfModule>
<IfModule mod_php5.c>
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
</IfModule>
service apache22 restart
apachectl -M | grep php5
Syntax OK
php5_module (shared)
pkg_add -r mc
rehash
pkg_info
gamin-0.1.10_4 A file and directory monitoring system
gettext-0.18_1 GNU gettext package
gio-fam-backend-2.24.1_1 FAM backend for GLib's GIO library
glib-2.24.1_1 Some useful routines of C programming (current stable versi
libiconv-1.13.1_1 A character set conversion library
libslang2-2.2.2_1 Routines for rapid alpha-numeric terminal applications deve
mc-4.7.2_1 Midnight Commander, a free Norton Commander Clone
pcre-8.02 Perl Compatible Regular Expressions library
perl-5.10.1_1 Practical Extraction and Report Language
pkg-config-0.23_1 A utility to retrieve information about installed libraries
png-1.4.3 Library for manipulating PNG images
python26-2.6.5 An interpreted object-oriented programming language
pkg_delete mc-4.7.2_1
pkg_delete mc\*
pkg_updating
pkg_add -r portupgrade
portupgrade -PP -r -R gettext
portupgrade -PP -r -R -a
top -m io -o total
zpool export backup
dd if=/dev/urandom of=/dev/ad6 bs=1m count=1000
zpool import backup
zpool status
pool: backup
state: ONLINE
status: One or more devices has experienced an unrecoverable error. An
attempt was made to correct the error. Applications are unaffected.
action: Determine if the device needs to be replaced, and clear the errors
using 'zpool clear' or replace the device with 'zpool replace'.
see: http://www.sun.com/msg/ZFS-8000-9P
scrub: none requested
config:
NAME STATE READ WRITE CKSUM
backup ONLINE 0 0 0
raidz1 ONLINE 0 0 0
ad4 ONLINE 0 0 0
ad6 ONLINE 0 0 10
ad10 ONLINE 0 0 0
errors: No known data errors
zpool scrub backup
zpool status
pool: backup
state: ONLINE
status: One or more devices has experienced an unrecoverable error. An
attempt was made to correct the error. Applications are unaffected.
action: Determine if the device needs to be replaced, and clear the errors
using 'zpool clear' or replace the device with 'zpool replace'.
see: http://www.sun.com/msg/ZFS-8000-9P
scrub: scrub completed after 0h0m with 0 errors on Sun Sep 5 23:05:03 2010
config:
NAME STATE READ WRITE CKSUM
backup ONLINE 0 0 0
raidz1 ONLINE 0 0 0
ad4 ONLINE 0 0 0
ad6 ONLINE 0 0 21 1.00M repaired
ad10 ONLINE 0 0 0
errors: No known data errors
zpool clear backup ad6
zpool status
pool: backup
state: ONLINE
scrub: none requested
config:
NAME STATE READ WRITE CKSUM
backup ONLINE 0 0 0
raidz1 ONLINE 0 0 0
ad4 ONLINE 0 0 0
ad6 ONLINE 0 0 0
ad10 ONLINE 0 0 0
errors: No known data errors
zpool offline backup ad4
zpool status
pool: backup
state: DEGRADED
status: One or more devices has experienced an unrecoverable error. An
attempt was made to correct the error. Applications are unaffected.
action: Determine if the device needs to be replaced, and clear the errors
using 'zpool clear' or replace the device with 'zpool replace'.
see: http://www.sun.com/msg/ZFS-8000-9P
scrub: none requested
config:
NAME STATE READ WRITE CKSUM
backup DEGRADED 0 0 0
raidz1 DEGRADED 0 0 0
ad4 OFFLINE 0 49 0
ad6 ONLINE 0 0 0
ad10 ONLINE 0 0 0
errors: No known data errors
zpool online backup ad4
zpool status
pool: backup
state: ONLINE
status: One or more devices has experienced an unrecoverable error. An
attempt was made to correct the error. Applications are unaffected.
action: Determine if the device needs to be replaced, and clear the errors
using 'zpool clear' or replace the device with 'zpool replace'.
see: http://www.sun.com/msg/ZFS-8000-9P
scrub: resilver completed after 0h0m with 0 errors on Sun Sep 5 23:00:15 2010
config:
NAME STATE READ WRITE CKSUM
backup ONLINE 0 0 0
raidz1 ONLINE 0 0 0
ad4 ONLINE 0 49 0 21.5K resilvered
ad6 ONLINE 0 0 1 15K resilvered
ad10 ONLINE 0 0 0 14K resilvered
errors: No known data errors
zpool import
pool: backup
id: 15744554445999282139
state: DEGRADED
status: One or more devices are missing from the system.
action: The pool can be imported despite missing or damaged devices. The
fault tolerance of the pool may be compromised if imported.
see: http://www.sun.com/msg/ZFS-8000-2Q
config:
backup DEGRADED
raidz1 DEGRADED
ad4 ONLINE
ad6 UNAVAIL cannot open
ad10 ONLINE
zpool list
no pools available
zpool import backup
zpool status backup
pool: backup
state: DEGRADED
status: One or more devices could not be opened. Sufficient replicas exist for
the pool to continue functioning in a degraded state.
action: Attach the missing device and online it using 'zpool online'.
see: http://www.sun.com/msg/ZFS-8000-2Q
scrub: none requested
config:
NAME STATE READ WRITE CKSUM
backup DEGRADED 0 0 0
raidz1 DEGRADED 0 0 0
ad4 ONLINE 0 0 0
1502173858046405299 UNAVAIL 0 227 0 was /dev/ad6
ad10 ONLINE 0 0 0
errors: No known data errors
zpool replace backup ad6
zpool status backup
pool: backup
state: ONLINE
scrub: resilver completed after 0h0m with 0 errors on Mon Sep 6 16:05:36 2010
config:
NAME STATE READ WRITE CKSUM
backup ONLINE 0 0 0
raidz1 ONLINE 0 0 0
ad4 ONLINE 0 0 0 31K resilvered
ad6 ONLINE 0 0 0 2.18M resilvered
ad10 ONLINE 0 0 0 33K resilvered
errors: No known data errors
FreeBSD rescue 8.1-STABLE FreeBSD 8.1-STABLE #0: Mon Jul 26 08:20:08 UTC 2010 root@fbsd64.hetzner.de:/usr/obj/usr/src/sys/GENERIC amd64
find /dev | egrep 'ad'
/dev/ad4
/dev/ad4s1
/dev/ad4s2
/dev/ad4s3
/dev/ad6
/dev/ad6s1
/dev/ad6s2
/dev/ad6s3
/dev/ad10
/dev/ad10s1
/dev/ad10s2
/dev/ad10s3
zpool list
no pools available
zpool create backup raidz ad{4,6,10}
zpool list
NAME SIZE USED AVAIL CAP HEALTH ALTROOT
backup 4.06T 220K 4.06T 0% ONLINE -
zpool status
pool: backup
state: ONLINE
scrub: none requested
config:
NAME STATE READ WRITE CKSUM
backup ONLINE 0 0 0
raidz1 ONLINE 0 0 0
ad4 ONLINE 0 0 0
ad6 ONLINE 0 0 0
ad10 ONLINE 0 0 0
errors: No known data errors
mount | grep /backup
backup on /backup (zfs, local)
df -h | grep backup
backup 2.7T 24K 2.7T 0% /backup
zpool destroy backup
A new virtualization container named “vimage” has been implemented. This is a jail with a virtualized instance of the FreeBSD network stack and can be created by using jail(8) command.
The pfil(9) framework for packet filtering in FreeBSD kernel now supports separate packet filtering instances like ipfw(4) for each VIMAGE jail.
Dear FreeBSD Community,
We are pleased to announce that Bjoern A. Zeeb has been awarded a grant
to improve FreeBSD's jail based virtualization infrastructure and to
continue to work on the virtual network stack. His employer, CK Software
GmbH is matching the Foundation's funding with hours.
FreeBSD has been well known for its jail based virtualization during the
last decade. With the import of the virtual network stack, FreeBSD's
operating system level virtualization has reached a new level.
This project includes cleanup of two years of import work and
development and, more notably, brings the infrastructure for a network
stack teardown. Cleanly shutting down a network stack in FreeBSD will be
the major challenge in the virtualization area to get the new feature to
production ready quality for the 9.x release
lifecycle.
Further, the project includes generalization of the virtual network
stack framework, factoring out common code. This will provide an
infrastructure and will ease virtualization of further subsystems like
SYSV/Posix IPC with minimal overhead. All further virtualized subsystems
will immediately benefit from shared debugging facilities, an essential
feature for early adopters of the new technology.
"Improved jail based virtualization support, that continues to be very
lightweight and as easily manageable as classic jails, will be a killer
feature for the next few years," said Bjoern A. Zeeb, FreeBSD developer.
He also added, "It will allow people to partition their FreeBSD server,
run simulations without racks of hardware, or provide thousands of
virtual instances in hosting environments fairly easy and efficiently.
While this follows the trend of green computing, it also adds to
FreeBSD's virtualization portfolio with Xen or other more heavyweight
hypervisor support, which can be mixed with jails as needed."
While work in this area will have to continue, the funding for this
project will end mid-July 2010.
Sincerely,
The FreeBSD Foundation
shutdown -r nowи после этого можно приступать к работе!