Update: UltraVNC 1.4.3.6 and UltraVNC SC 1.4.3.6: https://forum.uvnc.com/viewtopic.php?t=37885
Important: Please update to latest version before to create a reply, a topic or an issue: https://forum.uvnc.com/viewtopic.php?t=37864

Join us on social networks and share our announcements:
- Website: https://uvnc.com/
- GitHub: https://github.com/ultravnc
- Mastodon: https://mastodon.social/@ultravnc
- Facebook: https://www.facebook.com/ultravnc1
- X/Twitter: https://x.com/ultravnc1
- Reddit community: https://www.reddit.com/r/ultravnc
- OpenHub: https://openhub.net/p/ultravnc

Silent/Unattended/Automatic Installation without download

Post Reply
Doktor 2.0
Posts: 1
Joined: 2011-04-28 06:33
Location: Kingdom Bavaria

Silent/Unattended/Automatic Installation without download

Post by Doktor 2.0 »

Hi,

I made a installation script (batch/cmd) and want to full automatic install the UVNC with configuration files (INI/ACL).

Code: Select all

UltraVNC_1.0.8.2_Setup.exe /loadinf="UltraVNC.inf" /verysilent /norestart
That's ok, no questions but he want to download any drivers or something else.
But I don't want and need this downloads and what's more Internet is not available here, just internal net.

How I can disaple this downloads?

My UltraVNC.inf:

Code: Select all

[Setup]
Lang=de
Dir=C:\Program Files\UltraVNC
Group=UltraVNC
NoIcons=0
Components=ultravnc_server,ultravnc_viewer
Tasks=installservice,startservice,associate,cleanreg,acl
AclFile=UltraVNC.acl
SetupType=full
Thanks for help.
tm1
Posts: 2
Joined: 2011-07-25 12:22

Re: Silent/Unattended/Automatic Installation without downloa

Post by tm1 »

Hello !

I solve this problem by using following cmd files

install_svc1.cmd

Code: Select all


@echo off
   mode con cols=98 lines=40
echo ------------------
echo Cmdline is   : %0 %*
echo Started from : "%cd%"
set _tmp1_startdir_=%cd%
cd /d "%~dp0"
echo Workdir is   : "%cd%"
set _tmp1_workdir_=%~dp0
echo ------------------
echo.

echo install_svc1.cmd (ver 0.1c for ultravnc 1.0.4.x)

@echo [ %date% ~ %time% ] ====================
@echo [ %date% ~ %time% ] [***] opening xp sp2 embedded firewall for repeater, vncviewer and winvnc
@echo [ %date% ~ %time% ] ====================
if exist vnc-fw-open.cmd  call vnc-fw-open.cmd

@echo on
@echo [ %date% ~ %time% ] ====================
@echo [ %date% ~ %time% ] [***] installing repeater_service   version }=1.1.0.7 (2011-06-27)
@echo [ %date% ~ %time% ] ====================
pslist repeater
@echo [ %date% ~ %time% ] ------------------
net stop repeater_service
@echo [ %date% ~ %time% ] ------------------
pskill repeater
@echo [ %date% ~ %time% ] ------------------
taskkill /F /IM repeater.exe
@echo [ %date% ~ %time% ] ------------------
pslist repeater
@echo [ %date% ~ %time% ] ------------------
  @rem repeater -uninstall
  @rem repeater -install
if exist repeater.exe  start /min repeater.exe -install
@echo [ %date% ~ %time% ] ------------------
ping -w 1 -n 5 %ComputerName% >nul
@echo [ %date% ~ %time% ] ------------------
pslist repeater
@echo [ %date% ~ %time% ] ------------------
pskill repeater
@echo [ %date% ~ %time% ] ------------------
taskkill /F /IM repeater.exe
@echo [ %date% ~ %time% ] ------------------
  @rem net start repeater_service
@echo [ %date% ~ %time% ] ------------------
pslist repeater

@echo [ %date% ~ %time% ] ====================
@echo [ %date% ~ %time% ] [***] installing uvnc_service   version }=1.0.4.rc16 (2011-06-27)
@echo [ %date% ~ %time% ] ====================
pslist winvnc
@echo [ %date% ~ %time% ] ------------------
net stop uvnc_service
@echo [ %date% ~ %time% ] ------------------
pskill winvnc
@echo [ %date% ~ %time% ] ------------------
taskkill /F /IM winvnc.exe
@echo [ %date% ~ %time% ] ------------------
pslist winvnc
@echo [ %date% ~ %time% ] ------------------
  @rem winvnc -uninstall
if exist check_install.exe  check_install.exe silent
if exist winvnc.exe  start /min winvnc.exe -kill
@echo [ %date% ~ %time% ] ------------------
ping -w 1 -n 5 %ComputerName% >nul
@echo [ %date% ~ %time% ] ------------------
if exist winvnc.exe  start /min winvnc.exe -run
@echo [ %date% ~ %time% ] ------------------
ping -w 1 -n 5 %ComputerName% >nul
@echo [ %date% ~ %time% ] ------------------
if exist winvnc.exe  start /min winvnc.exe -uninstall
@echo [ %date% ~ %time% ] ------------------
ping -w 1 -n 15 %ComputerName% >nul
@echo [ %date% ~ %time% ] --- create x86 ---
if exist "%SystemDrive%\Program Files (x86)\UltraVNC\winvnc.exe" sc.exe create uvnc_service binPath= "\"%SystemDrive%\Program Files (x86)\UltraVNC\winvnc.exe\" -service" start= auto
@echo [ %date% ~ %time% ] ------------------
ping -w 1 -n 5 %ComputerName% >nul
@echo [ %date% ~ %time% ] --- create std ---
if exist "%SystemDrive%\Program Files\UltraVNC\winvnc.exe" sc.exe create uvnc_service binPath= "\"%SystemDrive%\Program Files\UltraVNC\winvnc.exe\" -service" start= auto
@echo [ %date% ~ %time% ] ------------------
ping -w 1 -n 5 %ComputerName% >nul
@echo [ %date% ~ %time% ] ------------------
if exist winvnc.exe  start /min winvnc.exe -install
@echo [ %date% ~ %time% ] ------------------
ping -w 1 -n 15 %ComputerName% >nul
@echo [ %date% ~ %time% ] ------------------
pskill winvnc
@echo [ %date% ~ %time% ] ------------------
taskkill /F /IM winvnc.exe

@echo [ %date% ~ %time% ] ------------------
net start uvnc_service
@echo [ %date% ~ %time% ] ------------------
pslist winvnc
@echo [ %date% ~ %time% ] ------------------
net start uvnc_service
@echo [ %date% ~ %time% ] ------------------
pslist winvnc

@echo [ %date% ~ %time% ] --- create x86 ---
if exist "%SystemDrive%\Program Files (x86)\UltraVNC\repeater.exe" sc.exe create repeater_service binPath= "\"%SystemDrive%\Program Files (x86)\UltraVNC\repeater.exe\" -service" start= auto
@echo [ %date% ~ %time% ] ------------------
ping -w 1 -n 5 %ComputerName% >nul
@echo [ %date% ~ %time% ] --- create std ---
if exist "%SystemDrive%\Program Files\UltraVNC\repeater.exe" sc.exe create repeater_service binPath= "\"%SystemDrive%\Program Files\UltraVNC\repeater.exe\" -service" start= auto
@echo [ %date% ~ %time% ] ------------------
ping -w 1 -n 5 %ComputerName% >nul
@echo [ %date% ~ %time% ] ------------------
net start repeater_service
@echo [ %date% ~ %time% ] ------------------
ping -w 1 -n 5 %ComputerName% >nul
@echo [ %date% ~ %time% ] ------------------
pslist repeater

@echo [ %date% ~ %time% ] ====================
@echo [ %date% ~ %time% ] [***] all done
@echo [ %date% ~ %time% ] ====================

@echo off
set _tmp1_sleep_=5
echo [info]   sleep for %_tmp1_sleep_% sec
echo.
sleep %_tmp1_sleep_%
set _tmp1_sleep_=
echo Back to dir  : "%_tmp1_startdir_%"
cd /d "%_tmp1_startdir_%"
set _tmp1_startdir_=
set _tmp1_workdir_=
echo ------------------

remove_svc1.cmd

Code: Select all


@echo off
   mode con cols=98 lines=40
echo ------------------
echo Cmdline is   : %0 %*
echo Started from : "%cd%"
set _tmp1_startdir_=%cd%
cd /d "%~dp0"
echo Workdir is   : "%cd%"
set _tmp1_workdir_=%~dp0
echo ------------------
echo.

echo remove_svc1.cmd (ver 0.1c for ultravnc 1.0.4.x)

@echo on
@echo [ %date% ~ %time% ] ====================
@echo [ %date% ~ %time% ] [***] removing repeater_service   version }=1.1.0.7 (2011-06-27)
@echo [ %date% ~ %time% ] ====================
pslist repeater
@echo [ %date% ~ %time% ] ------------------
net stop repeater_service
@echo [ %date% ~ %time% ] ------------------
pskill repeater
@echo [ %date% ~ %time% ] ------------------
taskkill /F /IM repeater.exe
@echo [ %date% ~ %time% ] ------------------
pslist repeater
@echo [ %date% ~ %time% ] ------------------
  @rem repeater -uninstall
  @rem repeater -install
@echo [ %date% ~ %time% ] ------------------
ping -w 1 -n 5 %ComputerName% >nul
@echo [ %date% ~ %time% ] ------------------
sc.exe delete repeater_service
@echo [ %date% ~ %time% ] ------------------
ping -w 1 -n 5 %ComputerName% >nul
@echo [ %date% ~ %time% ] ------------------
if exist repeater.exe  start /min repeater.exe -uninstall
@echo [ %date% ~ %time% ] ------------------
ping -w 1 -n 5 %ComputerName% >nul
@echo [ %date% ~ %time% ] ------------------
pslist repeater
@echo [ %date% ~ %time% ] ------------------
pskill repeater
@echo [ %date% ~ %time% ] ------------------
taskkill /F /IM repeater.exe
@echo [ %date% ~ %time% ] ------------------
@rem net start repeater_service
@echo [ %date% ~ %time% ] ------------------
pslist repeater

@echo [ %date% ~ %time% ] ====================
@echo [ %date% ~ %time% ] [***] removing uvnc_service   version }=1.0.4.rc16 (2011-06-27)
@echo [ %date% ~ %time% ] ====================
pslist winvnc
@echo [ %date% ~ %time% ] ------------------
net stop uvnc_service
@echo [ %date% ~ %time% ] ------------------
pskill winvnc
@echo [ %date% ~ %time% ] ------------------
taskkill /F /IM winvnc.exe
@echo [ %date% ~ %time% ] ------------------
pslist winvnc
@echo [ %date% ~ %time% ] ------------------
  @rem winvnc -uninstall
if exist check_install.exe  check_install.exe silent
if exist winvnc.exe  start /min winvnc.exe -kill
@echo [ %date% ~ %time% ] ------------------
ping -w 1 -n 5 %ComputerName% >nul
@echo [ %date% ~ %time% ] ------------------
sc.exe delete uvnc_service
@echo [ %date% ~ %time% ] ------------------
ping -w 1 -n 5 %ComputerName% >nul
@echo [ %date% ~ %time% ] ------------------
if exist winvnc.exe  start /min winvnc -uninstall
@echo [ %date% ~ %time% ] ------------------
ping -w 1 -n 5 %ComputerName% >nul
@echo [ %date% ~ %time% ] ------------------
pskill winvnc
@echo [ %date% ~ %time% ] ------------------
taskkill /F /IM winvnc.exe
@echo [ %date% ~ %time% ] ------------------
@rem net start uvnc_service
@echo [ %date% ~ %time% ] ------------------
@rem pslist winvnc
@echo [ %date% ~ %time% ] ------------------
@rem net start uvnc_service
@echo [ %date% ~ %time% ] ------------------
pslist winvnc

@echo [ %date% ~ %time% ] ====================
@echo [ %date% ~ %time% ] [***] all done
@echo [ %date% ~ %time% ] ====================

@echo off
set _tmp1_sleep_=5
echo [info]   sleep for %_tmp1_sleep_% sec
echo.
sleep %_tmp1_sleep_%
set _tmp1_sleep_=
echo Back to dir  : "%_tmp1_startdir_%"
cd /d "%_tmp1_startdir_%"
set _tmp1_startdir_=
set _tmp1_workdir_=
echo ------------------

tm1
Posts: 2
Joined: 2011-07-25 12:22

Re: Silent/Unattended/Automatic Installation without downloa

Post by tm1 »

I forgot this cmd file that will open windows xp/vista/seven internal firewall

vnc-fw-open.cmd

Code: Select all


@echo off

netsh firewall  add allowedprogram program = "%~dp0WinVNC.exe" name = "WinVNC Local" mode = ENABLE scope = CUSTOM addresses = 192.168.0.0/16,172.16.0.0/16,10.0.0.0/255.0.0.0,LocalSubnet
netsh firewall add allowedprogram "%~dp0WinVNC.exe" WinVNC ENABLE ALL

netsh firewall  add allowedprogram program = "%~dp0VNCViewer.exe" name = "VNCViewer Local" mode = ENABLE scope = CUSTOM addresses = 192.168.0.0/16,172.16.0.0/16,10.0.0.0/255.0.0.0,LocalSubnet
netsh firewall add allowedprogram "%~dp0VNCViewer.exe" VNCViewer ENABLE ALL

netsh firewall  add allowedprogram program = "%~dp0repeater.exe" name = "repeater Local" mode = ENABLE scope = CUSTOM addresses = 192.168.0.0/16,172.16.0.0/16,10.0.0.0/255.0.0.0,LocalSubnet
netsh firewall add allowedprogram "%~dp0repeater.exe" repeater ENABLE ALL

You can use and modify it freely of course.
B
800
800
Posts: 2338
Joined: 2009-09-09 14:05

Re: Silent/Unattended/Automatic Installation without downloa

Post by B »

Cool, thanks!

I knew of %0 but never %dp0.

http://htipe.wordpress.com/2008/10/09/the-dp0-variable/
Post Reply