Running the ZM binaries as a regular user?

A place for discussion of topics that are not specific to ZoneMinder. This could include Linux, Video4Linux, CCTV cameras or any other topic.
Post Reply
SyRenity
Posts: 301
Joined: Mon Jan 24, 2005 2:43 pm

Running the ZM binaries as a regular user?

Post by SyRenity »

Hi.

When I'm running any of the ZM binaries, as a regular user, I get no output (only help - but if I supply the correct parameters, it just exits and display nothing). When I trying to run them as a root, then I do able to launch them.

Any idea why it's happening, and how they can be launched via regular user account? (Note that all permissions are ok - in fact, they was compliled under the regular user, hence they have him as an owner.)
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

If you have run the binaries as root then the log files and shared memory segments may have been created as owned by root. Then if you try and run as a regular user they will not have permissions to access these resources. Make sure you delete old log files or shared memory segments that may be owned by root from a previous run before running as a different user.

Phil
SyRenity
Posts: 301
Joined: Mon Jan 24, 2005 2:43 pm

Post by SyRenity »

Hi Phil.

Logs can be deleted pretty easily, but how should I free the shared memory? By stopping the ZM service?

Thanks.
User avatar
zoneminder
Site Admin
Posts: 5215
Joined: Wed Jul 09, 2003 2:07 pm
Location: Bristol, UK
Contact:

Post by zoneminder »

It's best to stop ZM. This normally should delete the shared memory but may not always. Then use ipcs -m to list the shared memory segments and delete any remaining with ipcrm. The ZM segments should all have a key that starts with 0x7a6d20 so make sure you don't delete any of the other ones.

Phil
SyRenity
Posts: 301
Joined: Mon Jan 24, 2005 2:43 pm

Post by SyRenity »

Thanks for the explanation!
SyRenity
Posts: 301
Joined: Mon Jan 24, 2005 2:43 pm

Post by SyRenity »

Hi again.

After turning the logging higher, I discovered that the actual error was because the /etc/zm.conf, in Cordel's RPM, was root/apache read only. Good security practice, btw :).
Post Reply