c:
cd\
cls
for /f "tokens=1-2 delims=:" %%a in ('ipconfig^|find "IPv4"') do set ip=%%b
set ip=%ip:~1%
for /F "tokens=2 delims==" %%s in ('wmic bios get serialnumber /value') do set sn=%%s
echo IP address : %ip%
echo Computer Serical Number : %sn%
set file=\\192.168.4.157\samba\OA_Administrator\_System_info\%ip%_%sn%.txt
set file2=C:\%ip%_%sn%.txt
timeout 15
cls
timeout 150
wmic bios get serialnumber > %file%
wmic computersystem get "Model","Manufacturer" >> %file%
wmic computersystem get "Name", "UserName" >> %file%
wmic cpu get name >> %file%
wmic PATH Win32_PhysicalMemory get capacity >> %file%
wmic os get name >> %file%
wmic os get installdate >> %file%
wmic nicconfig get ipaddress,caption >> %file%
wmic nicconfig get macaddress,caption >> %file%
C:\Windows\Temp\cpuz\cpuz.exe -txt=%file%
wmic bios get serialnumber > %file2%
wmic computersystem get "Model","Manufacturer" >> %file2%
wmic computersystem get "Name", "UserName" >> %file2%
wmic cpu get name >> %file2%
wmic PATH Win32_PhysicalMemory get capacity >> %file2%
wmic os get name >> %file2%
wmic os get installdate >> %file2%
wmic nicconfig get ipaddress,caption >> %file2%
wmic nicconfig get macaddress,caption >> %file2%
timeout 15
cls
copy "\\192.168.4.157\samba\OA_Administrator\_System_info\C_ROOT_CMD\Windows\Temp\systeminfo_to_pc.cmd" "C:\Windows\Temp\" /y
cmd.exe /c start /min C:\Windows\Temp\systeminfo_to_pc.cmd
exit