MSFN Forum: Change administrator name - MSFN Forum

Jump to content



  • 4 Pages +
  • 1
  • 2
  • 3
  • 4
  • You cannot start a new topic
  • You cannot reply to this topic

Change administrator name Rate Topic: -----

#41 User is offline   rikgale 

  • uA lover
  • PipPipPip
  • Group: Members
  • Posts: 422
  • Joined: 01-November 04

Posted 16 May 2005 - 12:49 PM

Thanx Yzöwl. I know that there is a way to change this in nlite, but this is a useful way to change it without having re-nlite everytime I re-install on a different machine. Just change the cmdline.txt and burn. Cheers!


#42 User is offline   Yzöwl 

  • Wise Owl
  • Group: Super Moderator
  • Posts: 4,195
  • Joined: 13-October 04
  • OS:Windows 7 x64

Posted 16 May 2005 - 12:56 PM

MyDomain, on May 16 2005, 07:35 PM, said:

oke thanks, i'll try that!
But the usual stuff, you mean you normal unattended awsners?  :)
I specifically meant AdminPassword if you use one, AutoLogonCount, I'm not sure about, it may not work due to the name change.

#43 User is offline   rikgale 

  • uA lover
  • PipPipPip
  • Group: Members
  • Posts: 422
  • Joined: 01-November 04

Posted 17 May 2005 - 09:49 AM

The autologon part doesn't seem to work with the name change. I've just tried it. Had to change the logon name mannually and then it logged in as normal and installed everything.

Anyone any idea of how to get round this?

#44 User is offline   MyDomain 

  • Newbie
  • Group: Members
  • Posts: 39
  • Joined: 19-December 04
  • OS:none specified
  • Country: Country Flag

Posted 17 May 2005 - 09:58 AM

@Yzöwl or anyone else who knows

Well i tryed it, but it didn't work.

i added the following in my cmdlines.txt
[COMMANDS]
"REGEDIT /S tweaks.reg"
"Cleanup.cmd"
"renuser.exe "Administrator" "First Second""

I use a space in my name... maybe that is the reason why?
If so, what is the proper syntax?

Because renaming it without the quates around my name with the space it doesn't rename. I tested this when windows was running.

Thanks in advance :)

#45 User is offline   rikgale 

  • uA lover
  • PipPipPip
  • Group: Members
  • Posts: 422
  • Joined: 01-November 04

Posted 17 May 2005 - 10:08 AM

You may also wish to watch out for the small issue that I have encountered. If you rename the Administrator account and have a cleanup.cmd that deteles short cuts and other such items from your start menu and some of these are Administrator specfic i.e.
DEL "%systemdrive%\Documents and Settings\Administrator\Start Menu\Remote Assistance.lnk"

Then you will have to change the Administrator part to the new name of your admin account. This is only likely to be a problem if you are going to install this on many differenet computers with different Administraor names.

#46 User is offline   Yzöwl 

  • Wise Owl
  • Group: Super Moderator
  • Posts: 4,195
  • Joined: 13-October 04
  • OS:Windows 7 x64

Posted 17 May 2005 - 10:24 AM

@ MyDomain
Since you are using a cmd file first, try adding the command to that instead
:: Renaming Admin account
%~dp0renuser.exe Administrator "First Second"


#47 User is offline   rikgale 

  • uA lover
  • PipPipPip
  • Group: Members
  • Posts: 422
  • Joined: 01-November 04

Posted 17 May 2005 - 10:32 AM

You could also try placing the renuser before your cleanup.cmd, in cmdlines.txt. Althought Yzöwl's idea should do the same thing.

#48 User is offline   MyDomain 

  • Newbie
  • Group: Members
  • Posts: 39
  • Joined: 19-December 04
  • OS:none specified
  • Country: Country Flag

Posted 17 May 2005 - 10:43 AM

Oke thanks i'll just try that... can i copy Yzöwl's code and past it infront of the cleanup.cmd?

And @rikgale
You can prefent that in a much easyer way...
set UserStart=%UserProfile%\Menu Start
DEL /Q /F "%UserStart%\Windows Update.lnk"


Thanks for the quick reply!

[edit]
This only is usefull if you have the script running on that account ofcourse :)

[edit2] @Yzöwl's
I think i understand what you mean, add the command to the cleanup.cmd file like you posted it. So that the it will be done at the moment the cmdlines.txt calls on the cleanup.cmd... right?

#49 User is offline   rikgale 

  • uA lover
  • PipPipPip
  • Group: Members
  • Posts: 422
  • Joined: 01-November 04

Posted 17 May 2005 - 10:47 AM

Thanx :)

#50 User is offline   Yzöwl 

  • Wise Owl
  • Group: Super Moderator
  • Posts: 4,195
  • Joined: 13-October 04
  • OS:Windows 7 x64

Posted 17 May 2005 - 10:48 AM

Yes, you can just paste it in, as long as you are really renameing it to 'First Second', just to add also that the %~dp0 should not be necessary.

#51 User is offline   rikgale 

  • uA lover
  • PipPipPip
  • Group: Members
  • Posts: 422
  • Joined: 01-November 04

Posted 17 May 2005 - 10:53 AM

Just out of interest what does the %~dp0 do?

#52 User is offline   MyDomain 

  • Newbie
  • Group: Members
  • Posts: 39
  • Joined: 19-December 04
  • OS:none specified
  • Country: Country Flag

Posted 17 May 2005 - 10:56 AM

oke i now have this...
renuser.exe Administrator "First Second"

inside my cleanup.cmd

like this:

cmdow @ /HID
echo off

FOR %%i IN (D E F G H I J K L M N O P Q R S T U V W X Y Z) DO IF EXIST %%i:\UXPCD_IDENT.txt SET CDROM=%%i:

// Renaming Administrator Account
renuser.exe Administrator "First Second"           <-------First is your first name, Second you last... ofcrouse

EXIT


Were "First Second" ofcourse is my first and last name. :)

#53 User is offline   MyDomain 

  • Newbie
  • Group: Members
  • Posts: 39
  • Joined: 19-December 04
  • OS:none specified
  • Country: Country Flag

Posted 17 May 2005 - 02:41 PM

:hello: I do know btw what ofcourse causes the problem with not being able to log in automaticly...

Because the name and profile did change, but, the log-in that is filled in is still Administrator.

So we have to change the name that he automaticly fills in...
Is there a way to tell windows which username to use when logging in.

tnx for the help so far :D

[edit]
Maybe found a way?
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon]
"DefaultUserName"="Username"


Have not tryed it yet!

#54 User is offline   rikgale 

  • uA lover
  • PipPipPip
  • Group: Members
  • Posts: 422
  • Joined: 01-November 04

Posted 17 May 2005 - 02:56 PM

Mite I suggest calling that in a .reg file at the T-12 mark. Stick in cmdlines.txt and pray. I'll try it next time I do a build. I now have alot to remember!

#55 User is offline   MyDomain 

  • Newbie
  • Group: Members
  • Posts: 39
  • Joined: 19-December 04
  • OS:none specified
  • Country: Country Flag

Posted 18 May 2005 - 04:42 AM

Well my regtweak worked...

So to get the Documents and Settings folder plus you login name to change, but still be able to use autologin, you have to use this regtweak, along with the rename settings of Yzöwl...

Thanks! :hello:

#56 User is offline   Martin Zugec 

  • MSFN Expert
  • PipPipPipPipPipPip
  • Group: Members
  • Posts: 1,373
  • Joined: 24-January 04

Posted 18 May 2005 - 05:06 AM

rikgale: It is extremely usefull - it is variable containing path to running script, the main difference between %cd% is, that it is also working if you run script from UNC path...

#57 User is offline   Yzöwl 

  • Wise Owl
  • Group: Super Moderator
  • Posts: 4,195
  • Joined: 13-October 04
  • OS:Windows 7 x64

Posted 18 May 2005 - 06:57 AM

rikgale, on May 17 2005, 05:53 PM, said:

Just out of interest what does the %~dp0 do?
%0 is a variable automatically assigned to the running batch file, Cleanup.cmd. The additional parameters come from what is known as 'variable expansion and modification', where the tilde (~) expands the variable and the individual letters perform additional tasks. In this case d tells the variable to include the drive letter of the running batch, and p tells the variable to include the path of the running batch.
Therefore if your running batch, Cleanup.cmd is located in F:\UWXPCD\$OEM$\Cleanup.cmd, and renuser.exe was also in that same location, %~dp0renuser.exe would mean F:\UWXPCD\$OEM$\renuser.exe.

#58 User is offline   singk 

  • Newbie
  • Group: Members
  • Posts: 17
  • Joined: 10-February 05

Posted 01 July 2005 - 02:45 PM

Andries, on Apr 26 2004, 02:22 AM, said:

Is it possible that I change the "administrator" name/account (who has automatically created in a unattend file) renamed in "admin"?

I must change this after every unattended installation (for exclusive applications) but I would like that automatically if it is possible.
<{POST_SNAPBACK}>


What you can do is use the BUILTIN.EXE from OptimumX.com. It works great. I have been using it a while.

Put the builtin.exe in the $OEM$ directory.

install.cmd
@echo off

ECHO Modifying Boot Timeout
START "" /WAIT "%SystemRoot%\system32\bootcfg.exe" /timeout 4

ECHO Changing the Local Admin account
START "" /WAIT "builtin.exe" /newname:WhatEverName


cmdlines.txt
[COMMANDS]
".\INSTALLS.CMD"


This will be run at T-12

Sing

This post has been edited by singk: 01 July 2005 - 02:47 PM


#59 User is offline   bmalt 

  • Group: Members
  • Posts: 1
  • Joined: 18-July 05

Posted 18 July 2005 - 02:29 PM

The link referenced above to netuser.exe is broken now. The correct version of the netuser.exe file utility can be found at http://www.jsifaq.com/ - search for tip # 570, then click on the "netuser" link to download the file.

renuser is a little harder to find, but it should not be necessary if you have the correct netuser.exe. Netuser can rename the local administrator account to "admin" via the following line:

netuser.exe administrator /name:admin

many thanks to those who posted here and to whomever wrote netuser.exe.

#60 User is offline   Jotnar 

  • Member
  • PipPip
  • Group: Members
  • Posts: 186
  • Joined: 09-January 04

Posted 19 July 2005 - 07:15 AM

You can find both utilities in the following post on the MSFN forums :)

http://www.msfn.org/...showtopic=22645

Cheers


**I've fixed the links in my posts for netuser.exe. I'll fix the renuser.exe one as soon as I can up it to my site.

This post has been edited by Jotnar: 19 July 2005 - 07:20 AM


Share this topic:


  • 4 Pages +
  • 1
  • 2
  • 3
  • 4
  • You cannot start a new topic
  • You cannot reply to this topic

2 User(s) are reading this topic
0 members, 2 guests, 0 anonymous users



All trademarks mentioned on this page are the property of their respective owners
Copyright © 2001 - 2011 msfn.org
Privacy Policy