Skip to content
View in the app

A better way to browse. Learn more.

MSFN

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

setupcomplete.cmd didn't work after auto installation

Featured Replies

Hi Folks,

I want to auto run some commands after system finish auto installation by WAIK, so i added some command in Windows\Setup\Scripts\setupcomplete.cmd in install.wim, but after system finish installation, the setupcomplete.cmd couldn't be found. And i checked install.wim,

the file was there. Have you met this issue before?

second, i also tried firstlogoncommand, and it didn't work either, any tips for it? Thanks!


can you post the contents of your setupcomplete.cmd, my crystal ball is leaning towards syntax error. And it only runs once and under system authority prior to any logons, would be of no use but evil to leave that for a user to browse to.

Edited by iamtheky

  • Author

thanks. i just put some test command in setupcomplete.cmd, such as mkdir c:\11.

my first question is i have added setupcomplete.cmd in install.wim, but after installation, i couldn't find the file in target OS.

this

in case you have dagent installed. And it is normal for it to be gone when your system comes back up all prepped.

Edited by iamtheky

  • Author

yeah, i have read the web page, but i still couldn't know what should i do to fix the issue.

Besides, if i put some file in install.wim, after system finished installation, should these new added files would be in new system? if not, how should i get it work?

i would throw all your commands in to a batch file with a bunch of cmd /ks and pauses or an autoitscript with some error handling.

so that your setupcomplete.cmd has one line calling that script. At least then whatever is blowing up should be visible on screen. Its just a biatch to troubleshoot something that does not appear on screen nor log.

  • Author

i agreed with your idea, but first thing is that setupcomplete.cmd should be in target system. i did not see it after system finish installation. To be more clear, my steps were:

1. unmount install.wim and put setupcomplete.cmd in it and them commit

2. install Windows using Autounattend.xml from PXE, which means launch the whole installation from PXE and auto install system using Autounattend.xml

  • Author

i agreed with your idea, but first thing is that setupcomplete.cmd should be in target system. i did not see it after system finish installation. To be more clear, my steps were:

1. unmount install.wim and put setupcomplete.cmd in it and them commit

2. install Windows using Autounattend.xml from PXE, which means launch the whole installation from PXE and auto install system using Autounattend.xml

the issue why new added files couldn't be found was fixed, when i unmount the install.wim, i used wrong index.

But setupcomplete.cmd still did not run, after system boot up, i manually run it, it's ok. The following were my commands in setupcomplete.cmd

mkdir c:\1_test_1

c:

cd c:\

call c:\autoexec.bat

Edited by richard

  • Author

attached log files for setupcomplete.cmd, but i did not see any execution log in them.

setuperr.rar

Create an account or sign in to comment

Recently Browsing 0

  • No registered users viewing this page.

Account

Navigation

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.