skip duplicate util-vserver dir
[util-vserver.git] / man / vserver-copy.8
diff --git a/man/vserver-copy.8 b/man/vserver-copy.8
new file mode 100644 (file)
index 0000000..9481c49
--- /dev/null
@@ -0,0 +1,93 @@
+.TH "vserver-copy" "8" "0.3" "Mark Lawrence <nomad@null.net>" "System Administration"
+.SH "NAME"
+.LP 
+vserver-copy \- copy/move a virtual server.
+.SH "SYNTAX"
+.LP 
+vserver-copy [\fIoptions\fP] \fIvserver\fP \fInewname\fP 
+.LP 
+vserver-copy [\fIoptions\fP] \fIvserver\fP \fIhost\fP:[\fInewname\fP]
+.SH "DESCRIPTION"
+.LP 
+vserver-copy makes a copy of a virtual server using rsync. It will
+rewrite the vserver.conf configuration file with the new hostname and
+IP information when given. If the destination name contains a host
+specification then ssh/rsh will be used for the data transfer.
+
+vserver-copy can used on a running vserver, although naturally the
+consistency of open database files and the like cannot be guaranteed.
+A running vserver can however be safely moved from one root host to another
+using the \-s flag.
+
+If downtime is an issue when moving a virtual server across hosts you
+should first run vserver without the \-s flag. This will pre\-populate the
+destination filesystem requiring only updates to be made on the next
+invocation.
+.SH "OPTIONS"
+.LP 
+.TP 
+\fB\-h\fR,\fB-\-help\fR
+output usage information and exit
+.TP 
+\fB\-V\fR,\fB-\-version\fR
+output version information and exit
+.TP 
+\fB\-v\fR,\fB-\-verbose\fR
+show all output (normally only informational messages and warnings)
+.TP 
+\fB\-q\fR,\fB-\-quiet\fR
+suppress all output
+.TP 
+\fB\-d\fR,\fB-\-domain\fR domain
+the new DNS domain when changing name. Overwrites /etc/hosts. Must be
+used with \-i
+.TP 
+\fB\-i\fR,\fB-\-ip\fR address
+the new IP address when changing name. Overwrites /etc/hosts. Must be
+used with \-d
+.TP 
+\fB\-r\fR,\fB-\-vsroot\fR
+directory containing virtual servers. Defaults to "/vserver"
+.TP 
+\fB\-R\fR,\fB-\-rsh\fR
+use rsh instead of the default ssh for network transfer
+.TP
+\fB\-s\fR,\fB-\-stopstart\fR
+stop the virtual server before copying and start the new vserver afterwards.
+This really only makes sense if you are copying across root hosts and not
+changing names or IP addresses.
+.SH "FILES"
+.LP 
+\fI/etc/vservers/vserver.conf\fP 
+.SH "EXAMPLES"
+.LP 
+# Copy a template vserver (same IP addresses etc)
+
+/usr/sbin/vserver-copy template web01
+
+# Copy webserver with change in configuration
+
+/usr/sbin/vserver-copy -i 192.168.5.62 -d example.com template web62
+
+# Move a running vserver to another roothost
+
+/usr/sbin/vserver-copy -s web62 roothost02:
+
+.SH "BUGS"
+.LP 
+If a virtual server is moved from one root host to another a gratuitious
+ping should be sent to inform other devices on the local area network
+of the change in MAC address.
+
+Without this ping the devices will continue to attempt to reach the old
+MAC address for the length of their arp-cache timeout (10 minute default
+on Suns!).
+
+This functionality should probably be implmemented during the 
+"vserver <name> start" process.
+.SH "AUTHOR"
+.LP 
+Mark Lawrence <nomad@null.net>
+.SH "SEE ALSO"
+.LP 
+vserver(8)