[6/7/2007 12:26 AM] Jerome Fong wrote:
I was wondering if there was a way to save and duplicate my cygwin
installation so I can replicate it on a different machine.
[snip]
The following has worked for me over more than 6 computers since 99:
Do
mount -m > cygwin_mount_points.bat
Shut down all cygwin apps, including installed services. Archive the
entire cygwin directory with WinRAR (shareware, and so much better than
any xZip, will preserve symlinks).
cd to the cygwin dir and save all ntfs file permissions using Pedelstal
Software's NTSEC suite (shareware and still available at
http://www.winsite.com/bin/Info?500000034210), more specifically using
saveacl.
saveacl -r -usepriv * cygwin_permissions.txt
Use your text editor of preference and globally search and replace any
user names that have changed between the old and the new computer in
'cygwin_permissions.txt'.
Unpack the cygwin archive to your new location on the new computer.
cd to the new cygwin directory and run restacl with your updated ACL file.
restacl -usepriv -c -protect -propagate -hideprop cygwin_permissions.txt
Restore the mount points, possibly after editing directory locations in
'cygwin_mount_points.bat'.
And everything (or almost everything) should be like it was on the old
machine. Some things need reconfiguration though, like e.g. sshd.
Below is extract from the NTSEC README file.
================================================
Evaluation Version Stops Working After 30 Days
The NTSEC Security Tools contain several programs for manipulating and
viewing Windows security attributes. These programs provide a method for
scripting and non-destructively changing permissions and settings.
(Here is a partial list of the programs:)
NTFS
----
saveacl.exe - saves file, directory and ownership permissions to a file
restacl.exe - restores file permissions and ownership from a saveacl file
listacl.exe - lists file permissions in human readable format; query for
files/directories with given security attributes
swapacl.exe - swaps permissions from one user or group to another
igrant.exe - grants permisssions to users/groups on directories
irevoke.exe - revokes permissions to users/groups on directories
setowner.exe - sets the ownership of files and directories
audit.exe - add and remove audit triggers to files and directories
USERS AND GROUPS
-------------------
ntuser.exe - manipulate accounts and groups; query for accounts
with given attributes and settings.
DOCUMENTATION
-------------
readme.txt - this file
changes - detailed list of version by version changes
ntsec.htm - NTSEC manual
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/