Re: uid & gid problem restoring ubuntu made backup to new squeeze install
On Sat, May 14, 2011 at 1:17 AM, Brian Ryans wrote: > Quoting Juan R. de Silva on 2011-04-21 16:36: >> I preserved the user names for both of users in a new squeeze >> installation but UID and GID are different. So, by simply using 'cp - >> a' (or rsync) I would run into problem of their mismatch. >> >> Is there a simple and quick way to resolve it or I'll have to go trough >> this mess manually one step at a time? > > See find(1) and chown(1). If you prefer info documents, the {core,find}utils > files will be of much use. Be *very* careful doing this, as well. It's often easier to designate a much higher uid/gid space, such as 1000-11000, as a temporary holding space to change the uid's to one at a time, then switch the files owned by that uid to the target account. This helps avoid problems with temporary files created by both the old and new uid's, and the possibility of accidentally overlapping uid's. For example, my uid on the old machine is 500. My uid on the new uid is 520. My friend on the new machine has uid 500. I now alter all backup files, mail files, /var/spool/crontab files, and relevant /tmp/ files to be uid 500. But wait! I'm overlapping my friend! Chaos ensues. -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/BANLkTikO_t1nKUbe5mfBMyWXXh=oawy...@mail.gmail.com
Re: uid & gid problem restoring ubuntu made backup to new squeeze install
Quoting Juan R. de Silva on 2011-04-21 16:36: > I preserved the user names for both of users in a new squeeze > installation but UID and GID are different. So, by simply using 'cp - > a' (or rsync) I would run into problem of their mismatch. > > Is there a simple and quick way to resolve it or I'll have to go trough > this mess manually one step at a time? See find(1) and chown(1). If you prefer info documents, the {core,find}utils files will be of much use. -- _ Brian Ryans 8B2A 54C4 E275 8CFD 8A7D 5D0B 0AD0 B014 C112 13D0 . ( ) ICQ 43190205 | Mail/Jabber/Yahoo/MSN: brianlry...@gmail.com ..: X ASCII Ribbon Campaign Against HTML mail and v-cards: asciiribbon.org / \ Modern man has an approximately 140-character attention span. -- blr signature.asc Description: Digital signature
Re: uid & gid problem restoring ubuntu made backup to new squeeze install
On Thu, 21 Apr 2011 21:36:55 + (UTC), Juan wrote in message : > I'm in the process of moving from Ubuntu to Debian. I've installed > squeeze and want to restore some of 2 users home files and > directories from a backup made in Ubuntu. There are also some files > from /etc needed to be restored. > > I preserved the user names for both of users in a new squeeze > installation but UID and GID are different. So, by simply using 'cp - > a' (or rsync) I would run into problem of their mismatch. > > Is there a simple and quick way to resolve it or I'll have to go > trough this mess manually one step at a time? > > I know I could change UID and GID in Debian to Ubuntu values but I am > quite reluctant to go this way. ..read output of 'chown --help '. ;o) -- ..med vennlig hilsen = with Kind Regards from Arnt Karlsen ...with a number of polar bear hunters in his ancestry... Scenarios always come in sets of three: best case, worst case, and just in case. -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/20110422162439.0da9141b@celsius.local
Re: uid & gid problem restoring ubuntu made backup to new squeeze install
Dne, 21. 04. 2011 23:36:55 je Juan R. de Silva napisal(a): I'm in the process of moving from Ubuntu to Debian. I've installed squeeze and want to restore some of 2 users home files and directories from a backup made in Ubuntu. There are also some files from /etc needed to be restored. I preserved the user names for both of users in a new squeeze installation but UID and GID are different. How different? In Debian, the user numbers start at 1000 and go upwards. The user 1000 will be the first user you created (usually gets created during the installation of the OS). Then, once your OS is up and running, you can create new users with the GUI tool or with issuing the command 'adduser' (you must have root privileges to do that). The new users will start at 1001, then go to 1002, 1003 and so on. So just by creating them in a convenient order, you may get the UIDs you want (assuming that Ubuntu uses the same numbering schema, i.e. starting from 1000 up). If Ubuntu uses another schema (say, from down), the 'adduser --uid 100x' form should help. If you've just created your Debian users, then nothing will be lost by deleting them by issuing 'deluser --remove-all-files', and creating them from scratch with either of the methods above. Once you get your uids straight, you can start copying over the contents of the Ubuntu home dirs to Debian. Personally, I wouldn't copy them in bulk -- there's bound to be some useless cruft and old leftovers there. I'd copy them subdir by subdir, as needed. For example,after installing Wine, I'd copy over their respective .wine subdirs; and so on. So, by simply using 'cp - a' (or rsync) I would run into problem of their mismatch. Is there a simple and quick way to resolve it or I'll have to go trough this mess manually one step at a time? I know I could change UID and GID in Debian to Ubuntu values but I am quite reluctant to go this way. Thank you. HTH -- Cheerio, Klistvud http://bufferoverflow.tiddlyspot.com Certifiable Loonix User #481801 Please reply to the list, not to me. -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/1303461655.12161.5@compax
Re: uid & gid problem restoring ubuntu made backup to new squeeze install
On Thu, 21 Apr 2011 18:54:38 -0400, George Standish wrote: > On 21/04/11 06:16 PM, Juan R. de Silva wrote: > >> ..Debian uses the same values as Ubuntu does. Good. > > I'm sure you mean, Ubuntu uses the same as values as Debian does ;) You were reading my thoughts. :-) -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/ioqlbs$8ob$1...@dough.gmane.org
Re: uid & gid problem restoring ubuntu made backup to new squeeze install
On 21/04/11 06:16 PM, Juan R. de Silva wrote: ..Debian uses the same values as Ubuntu does. Good. I'm sure you mean, Ubuntu uses the same as values as Debian does ;) -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4db0b5ae.7040...@gmail.com
Re: uid & gid problem restoring ubuntu made backup to new squeeze install
On Thu, 21 Apr 2011 21:36:55 +, Juan R. de Silva wrote: > I'm in the process of moving from Ubuntu to Debian. I've installed > squeeze and want to restore some of 2 users home files and directories > from a backup made in Ubuntu. There are also some files from /etc needed > to be restored. > > I preserved the user names for both of users in a new squeeze > installation but UID and GID are different. So, by simply using 'cp - a' > (or rsync) I would run into problem of their mismatch. > > Is there a simple and quick way to resolve it or I'll have to go trough > this mess manually one step at a time? > > I know I could change UID and GID in Debian to Ubuntu values but I am > quite reluctant to go this way. > > Thank you. Looks that I've confused in my memory Debian UID's and GID's with Fedora ones. Just a quick glance resolved the "problem" - Debian uses the same values as Ubuntu does. Good. Sorry, for an invalid question. I'll try to be more careful in the future. Thank you. -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/ioqabf$gbq$1...@dough.gmane.org
uid & gid problem restoring ubuntu made backup to new squeeze install
I'm in the process of moving from Ubuntu to Debian. I've installed squeeze and want to restore some of 2 users home files and directories from a backup made in Ubuntu. There are also some files from /etc needed to be restored. I preserved the user names for both of users in a new squeeze installation but UID and GID are different. So, by simply using 'cp - a' (or rsync) I would run into problem of their mismatch. Is there a simple and quick way to resolve it or I'll have to go trough this mess manually one step at a time? I know I could change UID and GID in Debian to Ubuntu values but I am quite reluctant to go this way. Thank you. -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/ioq81m$v83$1...@dough.gmane.org