0

I have tried following code to silent install the MySQL but Script is not starting the SQL Server. below are the code

Filename: net.exe; Parameters:start MySQL; StatusMsg: Starting the service MySQL; Description: Starting the service mysql; Flags: runhidden

--> it is returning the value as 2 .

Please correct where i'm doing mistake.

[Files]
Source: "Sample.exe"; DestDir: "{app}"; Flags: ignoreversion

;MYSQL Install
Source: "mysql-5.1.73-winx64.msi"; DestDir: "{app}"; Flags: deleteafterinstall; Permissions: everyone-full; Check: MySQLIsNotInstalled
; AfterInstall: InstallMySQL


[Run]
Filename: msiexec.exe; Parameters:"/i ""{app}\mysql-5.1.73-winx64.msi"" /qn INSTALLDIR=""C:\Program Files\MySQL\MySQL Server 5.1\"" "; WorkingDir:{app}; StatusMsg:"Installing the mysql package"; Flags: runhidden;
Filename: C:\Program Files\MySQL\MySQL Server 5.1\bin\mysqld.exe; Parameters:--install MySQL --port=3306;StatusMsg: Installation the service MySQL;Description: Installation the service mysql; Flags: runhidden 
Filename: net.exe; Parameters:start MySQL; StatusMsg: Starting the service MySQL; Description: Starting the service mysql; Flags: runhidden
Filename: "{sys}\netsh.exe"; Parameters: firewall add portopening TCP 3306 MySQL; StatusMsg: "Enregistrement par défaut port MySQL ..."; Flags: runhidden; MinVersion: 0,5.01.2600sp2
;Filename: "{sys}\netsh.exe"; Parameters: "firewall set service type = fileandprint mode = enable"; StatusMsg: "Activation du partage de fichier et d'imprimante ..."; Flags: runhidden; MinVersion: 0,5.01.2600sp2
Vinooooo
  • 15
  • 4
  • 1
    What do you mean "it was not working?" What part isn't working? What errors are you getting? You need to give a lot more information. – mirtheil Dec 01 '21 at 20:17
  • See [Debugging non-working batch file or command executed from Inno Setup installer](https://stackoverflow.com/q/37324386/850848). – Martin Prikryl Dec 01 '21 at 20:27
  • Filename: net.exe; Parameters:start MySQL; StatusMsg: Starting the service MySQL; Description: Starting the service mysql; Flags: runhidden @mirtheil it is returning the value as 2. when i manually try to start the server it is not starting as well – Vinooooo Dec 02 '21 at 06:13

0 Answers0