COMSOL Multiphysics

295 views
Skip to first unread message

Graham Pugh

unread,
Aug 19, 2014, 10:38:29 AM8/19/14
to munk...@googlegroups.com
Hi all,

COMSOL has a method of unattended installation which I figure may be possible directly in Munki, but I'm not sure how. At present, I'm repackaging.

The method:

Download the latest version as an ISO from: Full DVD Download 4.1 GB (I think this requires a login first)
Mount the ISO
Extract "setupconfig.ini" and tweak settings.
Run /Volumes/COMSOL44/setup -s /path/to/amended/setupconfig.ini

Currently I'm using The Luggage to repackage, with the above process in the postinstall script, and then munkimport the pkg. Is that the best way?

Also, this method means that the "setup" process runs as root. The installation checks the license server, and fails if the current user is not in the license file. This means that I would have to leave root as a licensed user for it to work in Munki, which in turn (I think) means that anyone who runs COMSOL as sudo would gain access to the license, whether they are really licensed or not.  Is there a way of running a process as the current user, but with admin rights, within a package? 

Cheers, Graham



Gregory Neagle

unread,
Aug 19, 2014, 11:49:12 AM8/19/14
to munk...@googlegroups.com
On Aug 19, 2014, at 7:38 AM, Graham Pugh <g.r....@gmail.com> wrote:

Hi all,

COMSOL has a method of unattended installation which I figure may be possible directly in Munki, but I'm not sure how.

What is it? If It's a script that can be run and does not present a UI or expect user interaction, most likely Munki can run it.

At present, I'm repackaging.

The method:

Download the latest version as an ISO from: Full DVD Download 4.1 GB (I think this requires a login first)
Mount the ISO
Extract "setupconfig.ini" and tweak settings.
Run /Volumes/COMSOL44/setup -s /path/to/amended/setupconfig.ini

Currently I'm using The Luggage to repackage, with the above process in the postinstall script, and then munkimport the pkg. Is that the best way?

Also, this method means that the "setup" process runs as root. The installation checks the license server, and fails if the current user is not in the license file.

That's silly. You need elevated permissions to install, yet not every user that runs software should be required to have elevated permissions. It should check when the software is _launched_, not when it is _installed_.

This means that I would have to leave root as a licensed user for it to work in Munki, which in turn (I think) means that anyone who runs COMSOL as sudo would gain access to the license, whether they are really licensed or not.  Is there a way of running a process as the current user, but with admin rights, within a package? 

Not really. When Munki is installing something, there may be no GUI user at all, and therefore no "current user".

Munki can do only so much to address dumb vendor installers.


Cheers, Graham


Graham Pugh

unread,
Aug 19, 2014, 12:25:30 PM8/19/14
to munk...@googlegroups.com


On Tuesday, August 19, 2014 4:49:12 PM UTC+1, gregn...@mac.com wrote:
On Aug 19, 2014, at 7:38 AM, Graham Pugh <g.r....@gmail.com> wrote:

Hi all,

COMSOL has a method of unattended installation which I figure may be possible directly in Munki, but I'm not sure how.

What is it? If It's a script that can be run and does not present a UI or expect user interaction, most likely Munki can run it.

Yes, it just needs to run "/path/to/mountedISO/COMSOL44/setup -s /path/to/configsetup.ini"
So configsetup.ini would have to either be created, or included, as part of the process. Currently I include it (hence repackaging), but could it be created in the pkgsinfo plist?
 

Also, this method means that the "setup" process runs as root. The installation checks the license server, and fails if the current user is not in the license file.

That's silly. You need elevated permissions to install, yet not every user that runs software should be required to have elevated permissions. It should check when the software is _launched_, not when it is _installed_.

I know. Very annoying. It actually does both.  It's a FlexLM license, so I don't know if this is general for FlexLM software, but I suspect (and hope) not!

 
This means that I would have to leave root as a licensed user for it to work in Munki, which in turn (I think) means that anyone who runs COMSOL as sudo would gain access to the license, whether they are really licensed or not.  Is there a way of running a process as the current user, but with admin rights, within a package? 

Not really. When Munki is installing something, there may be no GUI user at all, and therefore no "current user".

Good point. I assume there's no way to run as a *specific* user (other than root), but still with the privileges to run the installer? This would be a UNIX thing rather than a Munki thing, I guess.
 
The alternative would be (I think), to package up the folder that's already been installed on a test machine. I already appear to have to do that with Matlab and Endnote to get the licensing to work, but I'm trying to avoid it where possible to make the update process quicker.

Munki can do only so much to address dumb vendor installers.

I have to say, It does a remarkable job!


Graham Pugh

unread,
Aug 19, 2014, 12:40:24 PM8/19/14
to munk...@googlegroups.com
It seems like running "sudo open /Application/someapp.app" does not mean the app is running as root user (unlike running the installer with admin rights).

Therefore, it seems relatively safe to leave "root" in the licensed user list on the FlexLM server.  People *could* enable root user, but that's going to extreme to get a seat for COMSOL.

Cheers, Graham


Joseph Rafferty

unread,
Aug 20, 2014, 1:14:41 PM8/20/14
to munk...@googlegroups.com
`sudo /Applications/someapp.app/Contents/MacOS/someapp` would run as root, however. But I wouldn't worry about it. Even if you didn't leave root as a licensed user, someone who has sudo access could just become another user on the box that is licensed. At that point it's a flaw in the vendor's licensing mechanism.


--
You received this message because you are subscribed to the Google Groups "munki-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to munki-dev+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages