RE: [Unattended] Windows: get logged on username/SID?
So: a question to those experienced with Win 2K/XP: How to I find out if there is a user logged in on the console (Remotely logged in users might also be relevant - but that's for revision 2 (-: ) and, if there is, how do I set up a logoff script for that user? Or perhaps there's a way of setting up a logoff script for the machine? Or, better still, force the machine to re-boot when a user logs out? You could try a shutdown -l or shutdown -r. Type shutdown /? on the prompt for all options and syntax. Can also be used from a remote machine. GreetZ, Stephan --- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562alloc_id=6184op=click ___ unattended-info mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/unattended-info
[Unattended] dosemu.bin segfaults
Are the following error messages from dosemu.bin (w/o arguments) known here, or should I ask the dosemu people? --- In file included from built-in global.conf:122 from include /etc/dosemu/dosemu.conf:148 Error in latin: (line 148) parse error Error in latin: (line 148) unrecognized command 'char' Error in vga: (line 211) parse error Error in : (line 312) unrecognized mouse flag 'flags' Error in : (line 312) unrecognized mouse flag 'nternaldriver' Error in : (line 418) unrecognized command 'ns' Error in : (line 418) unrecognized command Error in : (line 418) parse error Error in speaker emulated: (line 423) unrecognized command 'f' Error in speaker emulated: (line 423) unrecognized command 'restricted' Error in speaker emulated: (line 462) parse error Error in speaker emulated: (line 536) Lexer block stack underflow, unmatching if..else..endif Error in speaker emulated: (line 537) Lexer block stack underflow, unmatching if..else..endif Error in speaker emulated: (line 554) Lexer block stack underflow, unmatching if..else..endif Error in speaker emulated: (line 555) Lexer block stack underflow, unmatching if..else..endif Error in speaker emulated: (line 573) Lexer block stack underflow, unmatching if..else..endif Error in speaker emulated: (line 575) Lexer block stack underflow, unmatching if..else..endif --- Johannes --- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562alloc_id=6184op=click ___ unattended-info mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/unattended-info
AW: [Unattended] dosemu.bin segfaults
Ok, now I found an uncomfortable way to get dosemu.bin running: I cd to a directory /z/dosemu which contains the recent dosemu package from dosemu.org, run ./dosemu which throws an error (libXext.so.6 not found) and stops. After that I run dosemu.bin (from unattended) and it works. Without dosemu the dosemu.bin throws the same errors as before (see below). There seems to be no connection with unicode... Johannes -Ursprüngliche Nachricht- Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Auftrag von Johannes Simon Gesendet: Freitag, 14. Mai 2004 13:49 An: unattended Betreff: AW: [Unattended] dosemu.bin segfaults OK, I'm answering it myself... Using unicode_stop helps a lot. -Ursprüngliche Nachricht- Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Auftrag von Johannes Simon Gesendet: Freitag, 14. Mai 2004 13:17 An: unattended Betreff: [Unattended] dosemu.bin segfaults Are the following error messages from dosemu.bin (w/o arguments) known here, or should I ask the dosemu people? --- In file included from built-in global.conf:122 from include /etc/dosemu/dosemu.conf:148 Error in latin: (line 148) parse error Error in latin: (line 148) unrecognized command 'char' Error in vga: (line 211) parse error Error in : (line 312) unrecognized mouse flag 'flags' Error in : (line 312) unrecognized mouse flag 'nternaldriver' Error in : (line 418) unrecognized command 'ns' Error in : (line 418) unrecognized command Error in : (line 418) parse error Error in speaker emulated: (line 423) unrecognized command 'f' Error in speaker emulated: (line 423) unrecognized command 'restricted' Error in speaker emulated: (line 462) parse error Error in speaker emulated: (line 536) Lexer block stack underflow, unmatching if..else..endif Error in speaker emulated: (line 537) Lexer block stack underflow, unmatching if..else..endif Error in speaker emulated: (line 554) Lexer block stack underflow, unmatching if..else..endif Error in speaker emulated: (line 555) Lexer block stack underflow, unmatching if..else..endif Error in speaker emulated: (line 573) Lexer block stack underflow, unmatching if..else..endif Error in speaker emulated: (line 575) Lexer block stack underflow, unmatching if..else..endif --- Johannes --- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562alloc_id=6184op=click ___ unattended-info mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/unattended-info
[Unattended] Script to add applications after unattended has completed
Hi all, Following my earlier post about a script which installs applications after unattended has finished, here is the script I use. I run the script remotely using cygwin. At the moment, it's run manually as and when required. I propose to automate this using the cyg-apt.py script from http://www.lilypond.org/cygwin/cyg-apt and cron. The intention is to allow machines to periodically check for newly 'approved' software in our group and install it. This script is designed to be run under cygwin via ssh. Feel free to comment, adapt or otherwise use this. Yours, Frank #!/bin/sh # Addapp.sh - a shell script to re-start the 'unattended' procedure # on a workstation and run aribitrary numbers of batch files # (C) Frank Lee 2004 for Unattended.sourceforge.net # begin DEBUG # set -xv set -e # end DEBUG # Some definitions appropriate to the distribution # The usual unattended meanings here Z_PATH='\\ntserver\install' Z_USER=guest Z_PASS=guest # Machine will automatically log in as $UDOMAIN/$UUSER using $UPASS as a password UUSER=Administrator UPASS=SecretWord UDOMAIN=`hostname` # DEFDOM is the default domain for users to log into # (They never check...) DEFDOM=OURDOMAIN ## No user serviceable parts inside ## # fake echo command ECHO=/usr/bin/echo -e -n CRLF=\\r\\n # Test for valid number of applications APPS=$@ if [ -z $APPS ] ; then cat EOF Usage: $0 application [ application [ application ... ]] where application is the name of the .bat file in z:\scripts example: $0 acrobat.bat textpad.bat EOF exit fi # Check for Perl: first native win32 $ECHO Searching for Perl: WINPERL=1 PERL=`ls -1 /cygdrive/*/Perl/bin/perl.exe | tail -1` if [ -z $PERL ] ; then # Or in the default location \Perl\bin\perl.exe elsewhere PERL=`which perl` WINPERL=0 $ECHO Using CYGWIN\'s perl interpreter. This might not work properly. \\n else $ECHO ' 'Perl for WIN32 found. \\n fi if [ -z $PERL ] ; then $ECHO Not found \\n $ECHO Please install perl and then try again. \\n exit fi # Might not have OS installed on c: # Will unattended's scripts handle this? C=`echo $SYSTEMROOT | sed s/:.*//` # Create netinst/logs directories mkdir -p /cygdrive/$C/netinst/logs # Find a free drive letter $ECHO Searching for a free drive letter ... Z=empty for TESTDRIVE in z y x w v u t s r q p o n m l k j i h g f e d c ; do if ( [ $Z = empty ] [ ! -d /cygdrive/$TESTDRIVE ] ) ; then Z=$TESTDRIVE: CYGZ=$TESTDRIVE fi done if [ $Z = empty ] ; then $ECHO None available.\\n $ECHO You have 24 mounted filesystems, apparently.\\n exit fi $ECHO $Z \(/cygdrive/$CYGZ\) works for me. \\n # Map the network drive $ECHO Mounting $Z_PATH: \\n net use $Z $Z_PATH $Z_PASS /user:$Z_USER # Check that this is the right-looking place if [ ! -f /cygdrive/$CYGZ/bin/autolog.pl ] ; then echo Unable to map drive. Baling out. exit fi # Create tempcred.bat $ECHO Creating tempcred.bat, $ECHO @SET Z_USER=$Z_USER$CRLF /cygdrive/$C/netinst/tempcred.bat $ECHO @SET Z_PASS=$Z_PASS$CRLF /cygdrive/$C/netinst/tempcred.bat # Create permcred.bat $ECHO ' 'permcred.bat, $ECHO @SET Z=$Z$CRLF /cygdrive/$C/netinst/permcred.bat $ECHO @SET Z_PATH='\\'$Z_PATH$CRLF /cygdrive/$C/netinst/permcred.bat # Create UserWarn.vbs $ECHO ' 'userwarn.vbs, ( $ECHO 'msgbox Maintenance is required on this machine. chr(10)chr(13) _ ' $CRLF $ECHO ' Please reboot this machine as soon as convenient. ,0,'$DEFDOM' Admin Message' $CRLF ) /cygdrive/$C/netinst/userwarn.vbs # Create addapp.bat $ECHO ' 'addapp.bat ( $ECHO @ECHO OFF$CRLF $ECHO if %USERNAME%==$UUSER goto good$CRLF $ECHO wscript $C':\\netinst\\userwarn.vbs'$CRLF $ECHO goto end$CRLF $ECHO :good$CRLF $ECHO rundll32.exe user32.dll,LockWorkStation$CRLF $ECHO del $C:'\\netinst\\userwarn.vbs'$CRLF $ECHO call $C:'\\netinst\\mapznrun.bat '$Z:'\\bin\\todo.pl --go'$CRLF $ECHO :end ) /cygdrive/$C/netinst/addapp.bat $ECHO done \\n # copy mapznrun.bat $ECHO Copying mapznrun.bat, cp /cygdrive/$CYGZ/bin/mapznrun.bat /cygdrive/$C/netinst/ $ECHO ' 'completed. \\n # Set autologon to Administrator account as unattended. $ECHO Configuring auto-logon for $UUSER ... if [ $WINPERL -eq 1 ] ; then AULOGON=$Z\\bin\\autolog.pl TODO=$Z\\bin\\todo.pl else AULOGON=/cygdrive/$CYGZ/bin/autolog.pl TODO=/cygdrive/$CYGZ/bin/todo.pl fi $PERL $AULOGON --logon=1 --user=$UUSER --password=$UPASS --domain=$UDOMAIN $ECHO ' 'done.\\n # Set registry to lock workstation at next logon # and to run the logoff script. $ECHO Finding a spare file ... FILE=lk`date | md5sum | sed s/// | sed s/\ .*//`.reg while [ -f /tmp/$FILE ] ; do FILE=lk`date | md5sum | sed s/// | sed s/\ .*//`.reg done $ECHO ' '\($FILE\)\, adding registry settings ... ( $ECHO REGEDIT4 $CRLF $ECHO $CRLF $ECHO [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run] $CRLF $ECHO \AddApp\=\cmd /c $C:'netinstaddapp.bat'\ $CRLF ) /tmp/$FILE $ECHO ' 'done. \\n $ECHO Locating cygwin in DOS space:
RE: [Unattended] Windows: get logged on username/SID?
--On 14 May 2004 11:55 +0200 Stephan Lampe [ITXP] [EMAIL PROTECTED] wrote: You could try a shutdown -l or shutdown -r. That causes an immediate logout or reboot, doesn't it? What I would like to do is allow the user to continue working uninterrupted but convert their logoff into a reboot (whenever that is). Thanks, Frank --- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562alloc_id=6184op=click ___ unattended-info mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/unattended-info
RE: [Unattended] Windows auto update how to?
You could do this, but why would you as it would cost you bandwidth and dollars etc :-) Pats way is far superior as you only need to download the updates and hotfixes once etc. Aron -Original Message- From: John Lilley [mailto:[EMAIL PROTECTED] Sent: Friday, 14 May 2004 3:57 AM To: [EMAIL PROTECTED] Subject: [Unattended] Windows auto update how to? Hey Everyone, I was wondering if its possible to run auto update automatically after the last reboot to install all critical patches instead of using the winxp-update.bat? I've set todo.pl auconfig.pl 4 in base.bat but don't really know how to get it to update immediately after install. Oh and great work on the linux boot disk! I boot pxe and this saves me the headache of having to boot pxe twice for the drive format. :) John --- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562alloc_id=6184op=click ___ unattended-info mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/unattended-info
Re: [Unattended] Windows auto update how to?
True. But bandwidth isn't really an issue where I work and by it's nature the script is out of date in a few days after it's release. It would be one less script to manage. I guess I could allow the script to update (saving bandwidth) and run auto update to finish up the job. :) thanks, john Mangano, Aron wrote: You could do this, but why would you as it would cost you bandwidth and dollars etc :-) Pats way is far superior as you only need to download the updates and hotfixes once etc. Aron -Original Message- From: John Lilley [mailto:[EMAIL PROTECTED] Sent: Friday, 14 May 2004 3:57 AM To: [EMAIL PROTECTED] Subject: [Unattended] Windows auto update how to? Hey Everyone, I was wondering if its possible to run auto update automatically after the last reboot to install all critical patches instead of using the winxp-update.bat? I've set todo.pl auconfig.pl 4 in base.bat but don't really know how to get it to update immediately after install. Oh and great work on the linux boot disk! I boot pxe and this saves me the headache of having to boot pxe twice for the drive format. :) John --- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562alloc_id=6184op=click ___ unattended-info mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/unattended-info --- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562alloc_id=6184op=click ___ unattended-info mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/unattended-info
Re: [Unattended] Windows auto update how to?
Maybe it is a possibility to set up an SUS-server www.susserver.com and to point your workstations to there. Then u can be sure all the updates will be installed. Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate] WUServer=http://SUSServer.Company.com; WUStatusServer=http://SUSServer.Company.com [HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU] AUOptions=dword:0004 NoAutoRebootWithLoggedOnUsers=dword:0001 NoAutoUpdate=dword: RescheduleWaitTime=dword:0001 ScheduledInstallDay=dword: ScheduledInstallTime=dword:0004 UseWUServer=dword:0001 [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update] AUOptions=dword:0004 AUState=dword:0002 reg delete HKLM\Software\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update\LastWaitTimeout /force nul [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update] ScheduledInstallDate=2002.09.27 04:00:00 Rescheduled=dword:0001 With this there is also an overview of which client has (allready) upgraded. imdos On Fri, 2004-05-14 at 18:49, John Lilley wrote: True. But bandwidth isn't really an issue where I work and by it's nature the script is out of date in a few days after it's release. It would be one less script to manage. I guess I could allow the script to update (saving bandwidth) and run auto update to finish up the job. :) thanks, john Mangano, Aron wrote: You could do this, but why would you as it would cost you bandwidth and dollars etc :-) Pats way is far superior as you only need to download the updates and hotfixes once etc. Aron -Original Message- From: John Lilley [mailto:[EMAIL PROTECTED] Sent: Friday, 14 May 2004 3:57 AM To: [EMAIL PROTECTED] Subject: [Unattended] Windows auto update how to? Hey Everyone, I was wondering if its possible to run auto update automatically after the last reboot to install all critical patches instead of using the winxp-update.bat? I've set todo.pl auconfig.pl 4 in base.bat but don't really know how to get it to update immediately after install. Oh and great work on the linux boot disk! I boot pxe and this saves me the headache of having to boot pxe twice for the drive format. :) John --- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562alloc_id=6184op=click ___ unattended-info mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/unattended-info --- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562alloc_id=6184op=click ___ unattended-info mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/unattended-info --- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562alloc_id=6184op=click ___ unattended-info mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/unattended-info
Re: [Unattended] Windows auto update how to?
imdos wrote: Maybe it is a possibility to set up an SUS-server www.susserver.com and to point your workstations to there. Then u can be sure all the updates will be installed. We use this method, but unfortnately, it's bothersome to try and decipher WHEN WAU decides to pull updates, and when it decides to install them. Forcing it to update is problematic at best, mysterious and infuriating in general. We just hand-install critical (i.e. Blaster, Sasser) security fixs on new machines (or, once our unattended point is finished, todo.pl will do it :) ) and then leave them on overnight. It's far superior than hand-applying each new hotfix, service pack, and security patch, however. --- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562alloc_id=6184op=click ___ unattended-info mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/unattended-info
[Unattended] PXE Howto without RIS on Windows 2000 Server
Perhaps you would be interested in adding this to the documentation. I wrote a tutorial on how to setup PXE booting on Windows 2000 server without RIS. The tutorial includes setting up the DHCP portion of the PXE boot and it shows how to configure the Windows server to run TFTP as well (built-in. not necessary to use third party client). Cheers, Tyler Hepworth PXE HOWTO without RIS.tar.gz Description: Binary data
RE:RE: [Unattended] Windows: get logged on username/SID?
hi frank, in the project ani we realized a custom runonce key which is scanned by a perl script. the script is defined as a startupscript and executes every command which is specified under the custom registry key and removes the registry entries afterwards. you can use this approach to define a similar registry key and register the perl script as a logoff-script. your script then have only to check if a user is logged on and write an apropriate registry value e.g. 'shutdown -r'. tell me if you are interested in more details. _ hagen From: Dr. F. Lee [EMAIL PROTECTED] --On 14 May 2004 11:55 +0200 Stephan Lampe [ITXP] [EMAIL PROTECTED] wrote: You could try a shutdown -l or shutdown -r. That causes an immediate logout or reboot, doesn't it? What I would like to do is allow the user to continue working uninterrupted but convert their logoff into a reboot (whenever that is). Thanks, Frank --- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562alloc_id=6184op=click ___ unattended-info mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/unattended-info
Re: [Unattended] Windows auto update how to?
John Lilley [EMAIL PROTECTED] writes: True. But bandwidth isn't really an issue where I work and by it's nature the script is out of date in a few days after it's release. We usually do a pretty good job of keeping our scripts up-to-date in CVS. Well, except for this week, when I forgot to commit the addition of 840374 until just now :-). You can keep yourself up-to-date via anonymous CVS, or via the Web interface to same: http://cvs.sourceforge.net/viewcvs.py/unattended/unattended/install/scripts/winxpsp1-updates.bat (log) http://cvs.sourceforge.net/viewcvs.py/unattended/unattended/install/scripts/winxpsp1-updates.bat?rev=HEAD (script itself) If we are too slow for you, you can always add the update yourself and send us patches so that everyone may benefit :-). - Pat --- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562alloc_id=6184op=click ___ unattended-info mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/unattended-info
Re: AW: [Unattended] dosemu.bin segfaults
Johannes Simon [EMAIL PROTECTED] writes: OK, I'm answering it myself... Using unicode_stop helps a lot. That is odd, because we never invoke unicode_start. You are the first person to report this problem. If you want me to help debug it, first I need to know what you are doing differently from everybody else, if anything. We should probably move this discussion to unattended-devel. - Pat --- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562alloc_id=6184op=click ___ unattended-info mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/unattended-info
RE: [Unattended] Windows: get logged on username/SID?
At 06:13 AM 05/14/2004, you wrote: --On 14 May 2004 11:55 +0200 Stephan Lampe [ITXP] [EMAIL PROTECTED] wrote: You could try a shutdown -l or shutdown -r. That causes an immediate logout or reboot, doesn't it? What I would like to do is allow the user to continue working uninterrupted but convert their logoff into a reboot (whenever that is). Thanks, Frank Did you want it to catch only when they log off, or if they shutdown as well convert to a reboot? --- This SF.Net email is sponsored by: SourceForge.net Broadband Sign-up now for SourceForge Broadband and get the fastest 6.0/768 connection for only $19.95/mo for the first 3 months! http://ads.osdn.com/?ad_id=2562alloc_id=6184op=click ___ unattended-info mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/unattended-info