Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 9 Jan 2000 08:47:40 -0800 (PST)
From:      Nguyen Manh Tho <manhtho@yahoo.com>
To:        freebsd-questions@freebsd.org
Cc:        nmtho@dit.hcmut.edu.vn
Subject:   How can recognize the system and user account if you do not the system administrator ?
Message-ID:  <20000109164740.4144.qmail@web1906.mail.yahoo.com>

next in thread | raw e-mail | index | archive | help
Dear Sirs and Madams on Free BSD question list,

I am trying to convert all the accounts and data of
mail system from Turbo Linux to Free BSD Server, but I
still stack on this problem. I need all your help and
greatly appreciate them.

From Mr. Gianmarco Giovannelli's answer in last recent
day, I know that I have to do the following step:

1. Import the Linux passwd file to Free BSD format.

I can not find the script that help me does this work
(the awk script as Mr Dan Nelson's answer). If you
have this script, please send it to me. Will I copy
the Linux passwd file to Free BSD directory and run
this script on this passwd to convert them to Free BSD
format?

2. Copy all the users in the passwin from Turbo Linux
to Free BSD and leave unchanged the system users in
the Free BSD.

I do not know how to recognize the normal users and
the system ones. Do system users have the userid below
100 or 1000 ? Is there anything sign to recognize
between them ? I also do not know if I will copy all
the user on Linux passwd file to the Free BSD passwd
file or not?

3. Copy all the group in /etc/group from Turbo Linux
to Free BSD (but add only the users groups not the
system ones)
I am not the Sys Admin of this Linux Server and also
very new with the Free BSD server so I do not know
which group belong to users and which group is system
group ? Is there anything sign to recognize between
them ? 

4. Copy all the aliases in /etc/aliases from Turbo
Linux to Free BSD (add only the aliases pertinent to
the users)
I aslo do not know how to recognize the user aliases.

5. Copy all old mail from Linux to Free BSD. 
I can do this step.

6. Change the owner (user:group) to the files.
#!/usr/bin/perl
foreach $file (<*>)
{
($uid)=(getpwnam($file))[2];
($grp)=(getpwnam($file))[3];
chown($uid,$grp,$file);
};
As I understand from this script, it will get the
user_id and group of the mail file from the system to
the vaiables $uid and $grp and after that assign them
to this file by the procedure chown($uid,$grp,$file).
Why I have to change user:group to the files that also
have available in the Free BSD system????
Each user has one mail file,  will all files contain
on the directory that can be accessed by the root ? If
not, how can I change the suitable owner for all the
mail files ?

The last question here is could I do all the above
steps by the Perl script ? If you have, please send me
the sample one as referrence.

Please answer step by step, command by command if you
could.

I am sorry because I am very new and not experience on
the Unix system (My field is database and information
system) but I have to do this work for my University.
It's very urgent, so if my silly question trouble you,
please forgive me.

Please answering me both 2 address bellow:
nmtho@dit.hcmut.edu.vn
manhtho@yahoo.com
(I still can not send to the list from my University
mail address although can get all mail from this list)

Thank you very much for all relplies,I am looking
forward to them.
Have a good date.

Nguyen Manh Tho
Engineer, Assistant lecturer, 
Database Group,
Department of Information technology,
Hochiminh City University of Technology,
Hochiminh City, Vietnam.
__________________________________________________
Do You Yahoo!?
Talk to your friends online with Yahoo! Messenger.
http://im.yahoo.com


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20000109164740.4144.qmail>