averett@hatteras.cs.unc.edu (Shava Averett) (05/04/91)
Is there any way I can get the user's login directory from novell, other than hacking everybody's login script to create an environment variable (which I haven't tried but assume will work...) Every other file system I have ever worked will puts this into some sort of script accessible logical/symbol/variable/whatever-they-care-to-call-it, but I somehow don't see it in Novell... I am working in 2.15C but will be working on 3.11 real (*cough*) soon now... Thanks! Shava Nerad Averett shava@rad.unc.edu /* unc wants nothing to do with *my* opinions... */
steved@vaxc.cc.monash.edu.au (05/08/91)
In article <3662@borg.cs.unc.edu>, averett@hatteras.cs.unc.edu (Shava Averett) writes: > Is there any way I can get the user's login directory from novell, other > than hacking everybody's login script to create an environment variable > (which I haven't tried but assume will work...) Every other file system > I have ever worked will puts this into some sort of script accessible > logical/symbol/variable/whatever-they-care-to-call-it, but I somehow don't > see it in Novell... I am working in 2.15C but will be working on 3.11 > real (*cough*) soon now... > Well you may have to "hack" a little bit. Before the individual accounts login script is run the LOGIN program processes the system login script. You can access this by using SYSCON/ SUPERVISOR OPTIONS/SYSTEM LOGIN SCRIPT. Pressing F1 whilst you are there will be quite helpful. A few lines I like to put amongst the other stuff there goes like this. IF MEMBER OF "VOL1USERS" THEN BEGIN MAP G:=VOL1:USER\%LOGIN_NAME DRIVE G: END When you create the user accounts, use MAKEUSER to help create all their home directories and give them all membership of VOL1USERS and a default login script of a single semi-colon ";" . Hopes this helps SteveD.
cmp8118@sys.uea.ac.uk (Dave Cartwright) (05/09/91)
steved@vaxc.cc.monash.edu.au writes: >In article <3662@borg.cs.unc.edu>, averett@hatteras.cs.unc.edu (Shava Averett) writes: >> Is there any way I can get the user's login directory from novell, other >> than hacking everybody's login script to create an environment variable >> (which I haven't tried but assume will work...) Every other file system >> I have ever worked will puts this into some sort of script accessible >> logical/symbol/variable/whatever-they-care-to-call-it, but I somehow don't >> see it in Novell... I am working in 2.15C but will be working on 3.11 >> real (*cough*) soon now... >> The way I do it is to put the first line in the System Login Script as DOS SET LOGIN=%LOGIN_NAME (or something like that ... I'm 100 miles away from my NetWare system) After this, you can set things like the private drive to something sensible (mine is HAL\SYS:DATA\USER\<LOGIN_NAME>), and can use the Environment variable LOGIN in other situations. There's only one drawback with this ... you can only have directories of <=8 chars. Now this is OK sometimes, but occasionally you get the thing bombing out because it can't handle a name longer than 8 (SUPERVISOR springs to mind) You can get round this by (maybe) writing yourself a little C prog to take a string and return just the first 8 chars ... but watch out (eg) for two people with common 8-letters (like CARTWRIGHTD and CARTWRIGHTK) - these can cause problems. As it happens, my system (about 90 users) has no such clashes, and we've defined a username as first initial plus the first 7 letters of surname (if there are 7 letters). Examples are D. Cartwright -> DCARTWRI F. Bloggs -> FBLOGGS J. Smith -> JSMITH The only exception we've got is SUPERVISOR, which I have dealt with by putting a little clause in the System Login Script - IF User Name is Supervisor THEN Bugger about with it, otherwise LOGIN=%LOGIN_NAME. Hope that's of interest ... I thought I'd post it cos there may be more than one interested party. Dave C -- Dave Cartwright, | cmp8118@sys.uea.ac.uk or uk.ac.uea.sys School of Information Systems, | uucp : ...!ukc!uea-sys!cmp8118 University of East Anglia, | "Reality is an illusion brought on by Norwich, ENGLAND. NR4 7TJ. | lack of alcohol ..."
medici@dorm.rutgers.edu (Mark Medici) (05/10/91)
Assuming you mean "mail" directory, which is where the LOGIN file is stored for each user, you can do a DOS SET UserID = "%USER_ID" %USER_ID is the user's NetWare ID, which is the same number as the user's mail directory. If you are looking to get into the user's home directory, the preceding messages will do the trick. Instead of changing every user's login, just change the system login script. Depending on how you need to use this info, you may find a PD utility by David Harris useful. The utility is named HOME.EXE, and it should be available on splicer.cba.hawaii.edu and possibly on rodan.acs.syr.edu. Typing HOME will change you to your home directory. Typing HOME /m will change you to your mail directory. Typing HOME username or HOME username /m will change you to the specified user's home or mail directory, respectively. Hope this helps. -- ----------------------------------------------------------------------- Mark Medici/SysProg3 * RUCS/User Services * medici@elbereth.rutgers.edu -----------------------------------------------------------------------