SCO UNIX adding users and read(), truncating filenames

sys0001 at dircon.uucp sys0001 at dircon.uucp
Thu Jun 7 06:26:56 AEST 1990


I've been installing SCO UNIX 386 and I've come up against a couple of
problems.

First of all, I want to several users to share a home/login directory.
However, in the 'sysadmsh', when I try to enter the same home directory
for more than one user, I get an error: "Home directory already exists".
The program will not let me add the user until I change the home dir
to one which doesn't already exist. In fact this occurs with all logins,
whenever the home directory already exists. Is there any way of overcoming 
this?

Also, is there a command-line interface method of adding users. I've got a
batch of several hundred which I want to add in one go (from a Xenix system).
It would be handy if I could add them in one go, setting their ID number, 
group, login shell and home dir in a batch file. Any ideas on how this could 
be done? I'd like to do this in a way which keeps the 'tcb' C2 security files
up-to-date as well.

The second problem I've come across is that when I run a program from my
Xenix system under UNIX, it drops out (no error message or anything) back
to shell whenever it comes across a call to the C read() function to read
a record from a small database file into a structure: 
ie something along the lines of read(fd, &rec, sizeof(struct rec)).
It seems not to even get to the line following the read(), so I can't test
for return values.

This behaviour is exhibited wherever read() is called, apparently after the
relevant file has been opened with O_RDRW|O_SYNC. I've tried recompiling 
using the SCO UNIX dev system (with the -xenix flag) but no go. The program 
still drops out without any error message. Help/ideas/comments much 
appreciated! (by the way, this program currently works fine under Xenix 2.2).
If I remove the O_SYNC flag then the program seems to work OK.

Oddly, I noticed that under Xenix 2.2, the O_SYNC flag has a W on the end,
but in UNIX, it doesn't. This doesn't seem to be mentioned anywhere...?

Finally, can anyone let me know what the fix/patch is to switch off the
long filename truncation errors, which are getting to be a real pain.

Thanks!
-- 
sys0001 at dircon.UUCP   or   sys0001%dircon at ukc.ac.uk



More information about the Comp.unix.i386 mailing list