Mediaportal Silent installations (1 Viewer)

midiboy

Portal Pro
March 14, 2005
78
0
Dear Mediaportal Dev Team !

I used to include MP in my unattended installation DVD which installed MP silently. Now since RC1 this is a bit harder to do because of the deploy tool and the combination of the TV Plugin together with TV Server in one NSIS installer package.

I figured out most of the things needed for a silent installation for MP, MP TV Server and MySQL database engine out for myself but a few questions remain. Would you be so kind to share that information with me ?

1.

I am installing the MySQL silently using the /quiet /norestart switch (which by the way, gets rid of the MySQL advertisment popup that comes up when using the Deploy tool -> I guess you guys use the /passive switch?)

I then installed the service using this command:

mysqld-nt.exe --install MySQL

and placed the my.ini file that was there after a MySQL installation using the deploy tool in the My SQL Install folder.

is there Anything else I need to do to configure the MySQL database the way MP TV Server needs it ? How can I silently configure the default master password ? Is the database created automatically I guess ?

2.

Is there a way to silently install only the TV Client plugin and not the TV Server ? The /S switch for the NSIS installer will install both and I did not find a way to include only the TV Client Plugin but not the server.


In the future, would it be possible to maybe offer a way to script the deploy tool so that a silent installation would be easier ? eg. provide template answer files and tell the deploy tool to for instance silently install MP, TV Client plugin but no tv server etc.

Also it would be nice if local paths to needed components could be added to those answer files so that for instance the MySQL installation files could be delivered with the deploy package and no internet connectivity would be needed.

Thanks for your help,
Alex
 

midiboy

Portal Pro
March 14, 2005
78
0
Hi !

Made some progress on the silent installation thing.

As for question 1, this is what I am doing:

1. Install SQL database silently:

mysql-essential-5.0.45-win32.msi /quiet /norestart

2. copy my.ini from a previous installation to the MySQL install folder:

copy /Y .\my.ini "%PROGRAMFILES%\MySQL\MySQL Server 5.0\"

3. tell MySQL to start the server as a service:

cd "%PROGRAMFILES%\MySQL\MySQL Server 5.0\bin"
mysqld-nt.exe --install MySQL

4. start up the server:

net start mysql

5. Change root password and give it full privileges to connect from external and localhost client:

cd "%PROGRAMFILES%\MySQL\MySQL Server 5.0\bin"
mysql -u root
UPDATE mysql.user SET Password = PASSWORD('mediaportal') WHERE User = 'root';
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY 'mediaportal';
FLUSH PRIVILEGES;
exit

6. Restart the server:

net stop mysql
net start mysql

First connection from Mediaportal will now be successful. However, the above is actually not very secure since root access to the MySQL Server is enabled from everywhere. But I believe MP TV Server does the same thing ?


As for question 2:

Steven83 on IRC pointed me to the development wiki: TV-Server Development/NSISinstaller - MediaPortal Wiki Documentation

where the switches can be found !
Thanks !
Alex
 

MikPorter

New Member
January 7, 2011
2
1
Home Country
Wales Wales
In case it helps, I just made a package for deploying 1.2.1 across my home network (2 clients in Lounge/Kitchen and also to the 3 "normal" PCs that my wife, daughter and I use) with a Windows 2008R2 server in the attic running 1 DVB-S and 4 DVB-T tuners. The PCs are all Windows 7 so the reference to %PUBLIC% is to get the All Users Desktop location (checking for the presence of the program link)

I had to expand out the directx package (of course) and used 7zip to expand it into a subdirectory of the deploy folder. Everything else will run silently. The switches I've used are:-

directx_jun2010_redist\dxsetup /silent
vcredist2010_x86 /Q
vcredist2008_x86 /passive /norestart
wmp11-windowsxp-%PROCESSOR_ARCHITECTURE%-enu /Q
IF EXIST "%PUBLIC%\Desktop\MediaPortal.lnk" DEL "%PUBLIC%\Desktop\MediaPortal.lnk"
package-mediaportal /S
:WAITFORMEDIAPORTAL
IF NOT EXIST "%PUBLIC%\Desktop\MediaPortal.lnk" GOTO WAITFORMEDIAPORTAL
package-tvengine /S /noServer

I use %PROCESSOR_ARCHITECTURE% to call the correct Windows Media Player installation - having renamed the X64 image to AMD64 to make it work.

The WAITFORMEDIAPORTAL loop is there as a brute force way to make sure MP is installed before the plugin installation is attempted.

I've then included copying all the *.exe.config files from a previous installation into my script to perform the customisation of the clients. The script worked for a reinstall - haven't needed to try it on a new build yet.

Best regards
Mik
 

Users who are viewing this thread

Top Bottom