summaryrefslogtreecommitdiffstats
path: root/sbin/hastd/subr.c
Commit message (Collapse)AuthorAgeFilesLines
* Add my copyright.pjd2011-03-221-0/+1
| | | | MFC after: 1 week
* White space cleanups.pjd2011-03-221-4/+4
| | | | MFC after: 1 week
* When dropping privileges prefer capsicum over chroot+setgid+setuid.pjd2011-03-211-1/+15
| | | | | | | | | We can use capsicum for secondary worker processes and hastctl. When working as primary we drop privileges using chroot+setgid+setuid still as we need to send ioctl(2)s to ggate device, for which capsicum doesn't allow (yet). X-MFC after: capsicum is merged to stable/8
* Add snprlcat() and vsnprlcat() - the functions I'm always missing.pjd2011-03-211-0/+24
| | | | | | | They work as a combination of snprintf(3) and strlcat(3) - the caller can append a string build based on the given format. MFC after: 1 week
* Let the caller log info about successful privilege drop.pjd2011-02-031-2/+0
| | | | | | We don't want to log this in hastctl. MFC after: 1 week
* - Use pjdlog for assertions and aborts as this will log assert/abort messagepjd2011-01-311-2/+2
| | | | | | | | | to syslog if we run in background. - Asserts in proto.c that method we want to call is implemented and remove dummy methods from protocols implementation that are only there to abort the program with nice message. MFC after: 1 week
* Implement function that drops privileges by:pjd2011-01-281-0/+72
| | | | | | | | | | - chrooting to /var/empty (user hast home directory), - setting groups to 'hast' (user hast primary group), - setting real group id, effective group id and saved group id to 'hast', - setting real user id, effective user id and saved user id to 'hast'. At the end verify that those operations where successfull. MFC after: 1 week
* Please welcome HAST - Highly Avalable Storage.pjd2010-02-181-0/+118
HAST allows to transparently store data on two physically separated machines connected over the TCP/IP network. HAST works in Primary-Secondary (Master-Backup, Master-Slave) configuration, which means that only one of the cluster nodes can be active at any given time. Only Primary node is able to handle I/O requests to HAST-managed devices. Currently HAST is limited to two cluster nodes in total. HAST operates on block level - it provides disk-like devices in /dev/hast/ directory for use by file systems and/or applications. Working on block level makes it transparent for file systems and applications. There in no difference between using HAST-provided device and raw disk, partition, etc. All of them are just regular GEOM providers in FreeBSD. For more information please consult hastd(8), hastctl(8) and hast.conf(5) manual pages, as well as http://wiki.FreeBSD.org/HAST. Sponsored by: FreeBSD Foundation Sponsored by: OMCnet Internet Service GmbH Sponsored by: TransIP BV
OpenPOWER on IntegriCloud