Re: [RDD] Help RN just won't work

2020-10-23 Thread Tim Camp
Greetings,
Correction, retraction
Ok so, the runuser command runs out of ripcd with is running under root so
it should work just fine.

But RN still not working.

Tim


On Fri, Oct 23, 2020, 11:57 PM Tim Camp  wrote:

> Greetings,
>
> Thanks for those who emailed me with suggestions, however this is still a
> no go.
>
> I would like to point out that as of version 3 this is a different thing
> than it was in version 2.
>
> According to the rivendell operations guide
> **
> 13.8.37. Run Shell Command [RN]
> Module ripcd(8)
> Mnemonic RN
> Run a shell command.
> RN cmd!
> Run the shell command cmd.
>
> Note
>
> *The command is actually executed as:runuser -u user -g group cmd*
> where user and group are the values specified by the "RnRmlOwner=" and
> "RnRmlGroup="
> directives in the "[Identity]" section of rd.conf(5). See the runuser(1)
> man page for details
> concerning handling of the process environment.
> *
>
> The bold entry I have noted would seem to be important because if you
> specify
> RnRmlOwner=anyuser (except root)  and   RnRmlGroup=anygroup
> for example
>
> then the command runuser will fail because according to "man runuser"
> -g, --group=group
>   specify  the primary group,
>
> *this option is allowed for root user  only*
>
> so according to the documentation the only user you could specify that
> would work is root.
> This works in a terminal
>
> In Rivendell, Guess what? That doesn't work either.
>
> According to man runuser default path is /usr/local/bin thats where my
> scripts are
> the default env is /bin/bash or /bin/sh or /usr/bin/bash I'm all good with
> that
>
> My scripts run from the command line perfectly
>
> in a terminal "runuser -u root -g root cmd" runs perfection
> so the verdict is it should work except it doesn't
>
> Tim Camp
> WZEW-FM
>
>
>
>
>
> On Fri, Oct 23, 2020 at 1:49 PM Tim Camp  wrote:
>
>> Greetings,
>>
>> New install on CentOS 7 of Rivendell 3.4.1
>>
>> This is day number two of trying every possible thing I can think of as
>> to why this doesn't work.
>>
>> Things I have tried.
>>
>> 1. various settings for RNRmlOwner
>> rd rivendell
>> root root
>> rd users
>> rd rd
>>
>> 2. paths
>> RN with full path
>> RN without full path
>> changing $PATH
>>
>> 3. Running env
>> running the scripts with sh
>> running in bash
>>
>> Am I missing something?
>>
>> These scripts contain commands to control our consoles
>> which turn on channels, route audio, mute channels, etc
>> The scripts send data via udp to the console using /dev/udp
>> I have not had a problem with then in version 2.*
>> The scripts run fine in terminal as any user.
>>
>> Thanks for any thoughts or help on this.
>>
>> Tim Camp
>> WZEW-FM
>> Mobile, Al.
>>
>>
>>
>>
___
Rivendell-dev mailing list
Rivendell-dev@lists.rivendellaudio.org
http://caspian.paravelsystems.com/mailman/listinfo/rivendell-dev


Re: [RDD] Help RN just won't work

2020-10-23 Thread Tim Camp
Greetings,

Thanks for those who emailed me with suggestions, however this is still a
no go.

I would like to point out that as of version 3 this is a different thing
than it was in version 2.

According to the rivendell operations guide
**
13.8.37. Run Shell Command [RN]
Module ripcd(8)
Mnemonic RN
Run a shell command.
RN cmd!
Run the shell command cmd.

Note

*The command is actually executed as:runuser -u user -g group cmd*
where user and group are the values specified by the "RnRmlOwner=" and
"RnRmlGroup="
directives in the "[Identity]" section of rd.conf(5). See the runuser(1)
man page for details
concerning handling of the process environment.
*

The bold entry I have noted would seem to be important because if you
specify
RnRmlOwner=anyuser (except root)  and   RnRmlGroup=anygroup
for example

then the command runuser will fail because according to "man runuser"
-g, --group=group
  specify  the primary group,

*this option is allowed for root user  only*

so according to the documentation the only user you could specify that
would work is root.
This works in a terminal

In Rivendell, Guess what? That doesn't work either.

According to man runuser default path is /usr/local/bin thats where my
scripts are
the default env is /bin/bash or /bin/sh or /usr/bin/bash I'm all good with
that

My scripts run from the command line perfectly

in a terminal "runuser -u root -g root cmd" runs perfection
so the verdict is it should work except it doesn't

Tim Camp
WZEW-FM





On Fri, Oct 23, 2020 at 1:49 PM Tim Camp  wrote:

> Greetings,
>
> New install on CentOS 7 of Rivendell 3.4.1
>
> This is day number two of trying every possible thing I can think of as to
> why this doesn't work.
>
> Things I have tried.
>
> 1. various settings for RNRmlOwner
> rd rivendell
> root root
> rd users
> rd rd
>
> 2. paths
> RN with full path
> RN without full path
> changing $PATH
>
> 3. Running env
> running the scripts with sh
> running in bash
>
> Am I missing something?
>
> These scripts contain commands to control our consoles
> which turn on channels, route audio, mute channels, etc
> The scripts send data via udp to the console using /dev/udp
> I have not had a problem with then in version 2.*
> The scripts run fine in terminal as any user.
>
> Thanks for any thoughts or help on this.
>
> Tim Camp
> WZEW-FM
> Mobile, Al.
>
>
>
>
___
Rivendell-dev mailing list
Rivendell-dev@lists.rivendellaudio.org
http://caspian.paravelsystems.com/mailman/listinfo/rivendell-dev


Re: [RDD] Fwd: Help RN just won't work

2020-10-23 Thread Robert Jeffares

Tim,

Try locating the script you want to use in /usr/bin/

I had this issue a while ago with a script on V2.x and putting the 
scripts in there solved the problem.


The reason has to do with permissions. There may be another way. This 
worked.


I would expect similar in V 3.x. I have one copy running which does not 
use any RN calls.


I will use it to test.

regards

Robert

On 24/10/20 8:39 am, Tim Camp wrote:


-- Forwarded message -
From: *Tim Camp* mailto:t...@dotcom1.net>>
Date: Fri, Oct 23, 2020, 2:38 PM
Subject: Re: [RDD] Help RN just won't work
To: Kit Haskins mailto:k...@ka0wuc.org>>


Greetings,
Thanks so much for your reply Kit.
/dev/udp is not an actual device that you will see in /dev.
It is a bash call to open a udp port to read or write to/from.

You can also do this in bash with tcp.
For example
Some Data > /dev/udp//
Some Data > /dev/tcp/
I used it like
$printf "data" > /dev/udp/ip/port

Cheers

Tim Camp
WZEW-FM




On Fri, Oct 23, 2020, 2:21 PM Kit Haskins > wrote:


I don't have a /dev/udp in either my Ubuntu (20.04) nor Centos 6.8
(old box)

While what I'm going to suggest fixed another problem with
permissions, I'll toss it out here, knowing there are many smarter
people reading this thread:

I had issues with access to the serial ports /dev/ttyUSBx ...   I
added the "dialout" group to the rduser.   Which resolved my
issues.   As I don't have a "/dev/udp" to study under a
microscope, I can blindly suggest

ll /dev/udp
see what group it is affiliated with and

usermod -a -G groupname username

If /dev/udp is some executable binary and if you feel brave enough
to set the sticky bit

chmod 4755 /dev/udp


I'm also still running 2.19.3 here ...


I have been reading your progress on the migration to 3.4.x and
switching from Ubuntu to CentOS 7, I appreciate your notes and
comments as you progress thru the challenge.   If you continue to
beat up on it, eventually it just might work :-)

---
Thru the Ethernet, past the Gateway, off the modem pool, nothing
but NET .
k...@ka0wuc.org 


 On Fri, 23 Oct 2020 12:49:32 -0600 *Tim Camp mailto:t...@dotcom1.net>>* wrote 

Greetings,

New install on CentOS 7 of Rivendell 3.4.1

This is day number two of trying every possible thing I can
think of as to why this doesn't work.

Things I have tried.

1. various settings for RNRmlOwner
rd rivendell
root root
rd users
rd rd

2. paths
RN with full path
RN without full path
changing $PATH

3. Running env
running the scripts with sh
running in bash

Am I missing something?

These scripts contain commands to control our consoles
which turn on channels, route audio, mute channels, etc
The scripts send data via udp to the console using /dev/udp
I have not had a problem with then in version 2.*
The scripts run fine in terminal as any user.

Thanks for any thoughts or help on this.

Tim Camp
WZEW-FM
Mobile, Al.



___
Rivendell-dev mailing list
Rivendell-dev@lists.rivendellaudio.org

http://caspian.paravelsystems.com/mailman/listinfo/rivendell-dev



___
Rivendell-dev mailing list
Rivendell-dev@lists.rivendellaudio.org

http://caspian.paravelsystems.com/mailman/listinfo/rivendell-dev


___
Rivendell-dev mailing list
Rivendell-dev@lists.rivendellaudio.org
http://caspian.paravelsystems.com/mailman/listinfo/rivendell-dev


--
Communication Consultants 2020 Limited
64 Warner Park Avenue
Laingholm
Auckland 0604
New Zealand

___
Rivendell-dev mailing list
Rivendell-dev@lists.rivendellaudio.org
http://caspian.paravelsystems.com/mailman/listinfo/rivendell-dev


Re: [RDD] Help RN just won't work

2020-10-23 Thread Lorne Tyndale
Tim,

Two things.  First, double check the following settings in the
[Identity] section of your /etc/rd.conf file

RnRmlOwner=
RnRmlGroup=

That is supposed to tell the system what user/group to run the RML's as.

If that doesn't work, I realize this goes against some of the suggested
Linux / Rivendell security conventions, but for testing purposes have
you tried changing the user that the Rivendell daemons run as by
systemd?

As root, edit the file:

/lib/systemd/system/rivendell.service

Then in the [Service] section add a line:

User=

where  is the logged in user that runs RDAirplay and other
Rivendell apps.

Also make sure the User= part is a capital U with the "ser" lower case. 
I made the mistake once of having it all lower case and it didn't work.

This should cause your daemons to run as the same user as your logged in
user.  Again not necessarily the best thing to do for security purposes,
but it might help you troubleshoot the issue.  Of course if you make
changes to your systemd  configuration file then you'll need to restart
the Rivendell services.  As root:

systemctl stop rivendell
systemctl start rivendell

Lorne Tyndale



>  Original Message 
> Subject: [RDD] Help RN just won't work
> From: Tim Camp 
> Date: Fri, October 23, 2020 2:49 pm
> To: User discussion about the Rivendell Radio Automation System
> 
> 
> 
> Greetings,
> 
> New install on CentOS 7 of Rivendell 3.4.1
> 
> This is day number two of trying every possible thing I can think of as to
> why this doesn't work.
> 
> Things I have tried.
> 
> 1. various settings for RNRmlOwner
> rd rivendell
> root root
> rd users
> rd rd
> 
> 2. paths
> RN with full path
> RN without full path
> changing $PATH
> 
> 3. Running env
> running the scripts with sh
> running in bash
> 
> Am I missing something?
> 
> These scripts contain commands to control our consoles
> which turn on channels, route audio, mute channels, etc
> The scripts send data via udp to the console using /dev/udp
> I have not had a problem with then in version 2.*
> The scripts run fine in terminal as any user.
> 
> Thanks for any thoughts or help on this.
> 
> Tim Camp
> WZEW-FM
> Mobile, Al.___
> Rivendell-dev mailing list
> Rivendell-dev@lists.rivendellaudio.org
> http://caspian.paravelsystems.com/mailman/listinfo/rivendell-dev
___
Rivendell-dev mailing list
Rivendell-dev@lists.rivendellaudio.org
http://caspian.paravelsystems.com/mailman/listinfo/rivendell-dev


[RDD] Fwd: Help RN just won't work

2020-10-23 Thread Tim Camp
-- Forwarded message -
From: Tim Camp 
Date: Fri, Oct 23, 2020, 2:38 PM
Subject: Re: [RDD] Help RN just won't work
To: Kit Haskins 


Greetings,
Thanks so much for your reply Kit.
/dev/udp is not an actual device that you will see in /dev.
It is a bash call to open a udp port to read or write to/from.

You can also do this in bash with tcp.
For example
Some Data > /dev/udp//
Some Data > /dev/tcp/
I used it like
$printf "data" > /dev/udp/ip/port

Cheers

Tim Camp
WZEW-FM




On Fri, Oct 23, 2020, 2:21 PM Kit Haskins  wrote:

> I don't have a /dev/udp in either my Ubuntu (20.04) nor Centos 6.8 (old
> box)
>
> While what I'm going to suggest fixed another problem with permissions,
> I'll toss it out here, knowing there are many smarter people reading this
> thread:
>
> I had issues with access to the serial ports /dev/ttyUSBx ...   I added
> the "dialout" group to the rduser.   Which resolved my issues.   As I don't
> have a "/dev/udp" to study under a microscope, I can blindly suggest
>
> ll /dev/udp
> see what group it is affiliated with and
>
> usermod -a -G groupname username
>
> If /dev/udp is some executable binary and if you feel brave enough to set
> the sticky bit
>
> chmod 4755 /dev/udp
>
>
> I'm also still running 2.19.3 here ...
>
>
> I have been reading your progress on the migration to 3.4.x and switching
> from Ubuntu to CentOS 7, I appreciate your notes and comments as you
> progress thru the challenge.   If you continue to beat up on it, eventually
> it just might work :-)
>
> ---
> Thru the Ethernet, past the Gateway, off the modem pool, nothing but NET .
> k...@ka0wuc.org
>
>
>  On Fri, 23 Oct 2020 12:49:32 -0600 *Tim Camp  >* wrote 
>
> Greetings,
>
> New install on CentOS 7 of Rivendell 3.4.1
>
> This is day number two of trying every possible thing I can think of as to
> why this doesn't work.
>
> Things I have tried.
>
> 1. various settings for RNRmlOwner
> rd rivendell
> root root
> rd users
> rd rd
>
> 2. paths
> RN with full path
> RN without full path
> changing $PATH
>
> 3. Running env
> running the scripts with sh
> running in bash
>
> Am I missing something?
>
> These scripts contain commands to control our consoles
> which turn on channels, route audio, mute channels, etc
> The scripts send data via udp to the console using /dev/udp
> I have not had a problem with then in version 2.*
> The scripts run fine in terminal as any user.
>
> Thanks for any thoughts or help on this.
>
> Tim Camp
> WZEW-FM
> Mobile, Al.
>
>
>
> ___
> Rivendell-dev mailing list
> Rivendell-dev@lists.rivendellaudio.org
> http://caspian.paravelsystems.com/mailman/listinfo/rivendell-dev
>
>
>
> ___
> Rivendell-dev mailing list
> Rivendell-dev@lists.rivendellaudio.org
> http://caspian.paravelsystems.com/mailman/listinfo/rivendell-dev
>
___
Rivendell-dev mailing list
Rivendell-dev@lists.rivendellaudio.org
http://caspian.paravelsystems.com/mailman/listinfo/rivendell-dev


Re: [RDD] Help RN just won't work

2020-10-23 Thread Kit Haskins
I don't have a /dev/udp in either my Ubuntu (20.04) nor Centos 6.8 (old box)



While what I'm going to suggest fixed another problem with permissions, I'll 
toss it out here, knowing there are many smarter people reading this thread:



I had issues with access to the serial ports /dev/ttyUSBx ...   I added the 
"dialout" group to the rduser.   Which resolved my issues.   As I don't have a 
"/dev/udp" to study under a microscope, I can blindly suggest 



ll /dev/udp 

see what group it is affiliated with and 



usermod -a -G groupname username


If /dev/udp is some executable binary and if you feel brave enough to set the 
sticky bit



chmod 4755 /dev/udp 





I'm also still running 2.19.3 here ...    





I have been reading your progress on the migration to 3.4.x and switching from 
Ubuntu to CentOS 7, I appreciate your notes and comments as you progress thru 
the challenge.   If you continue to beat up on it, eventually it just might 
work :-)



---

Thru the Ethernet, past the Gateway, off the modem pool, nothing but NET .

mailto:k...@ka0wuc.org




 On Fri, 23 Oct 2020 12:49:32 -0600 Tim Camp  wrote 


Greetings,


New install on CentOS 7 of Rivendell 3.4.1



This is day number two of trying every possible thing I can think of as to why 
this doesn't work.



Things I have tried.



1. various settings for RNRmlOwner

rd rivendell

root root

rd users

rd rd



2. paths

RN with full path

RN without full path

changing $PATH



3. Running env

running the scripts with sh

running in bash



Am I missing something?



These scripts contain commands to control our consoles

which turn on channels, route audio, mute channels, etc

The scripts send data via udp to the console using /dev/udp

I have not had a problem with then in version 2.*

The scripts run fine in terminal as any user.



Thanks for any thoughts or help on this.



Tim Camp

WZEW-FM

Mobile, Al.








___
Rivendell-dev mailing list 
mailto:Rivendell-dev@lists.rivendellaudio.org 
http://caspian.paravelsystems.com/mailman/listinfo/rivendell-dev___
Rivendell-dev mailing list
Rivendell-dev@lists.rivendellaudio.org
http://caspian.paravelsystems.com/mailman/listinfo/rivendell-dev


[RDD] Help RN just won't work

2020-10-23 Thread Tim Camp
Greetings,

New install on CentOS 7 of Rivendell 3.4.1

This is day number two of trying every possible thing I can think of as to
why this doesn't work.

Things I have tried.

1. various settings for RNRmlOwner
rd rivendell
root root
rd users
rd rd

2. paths
RN with full path
RN without full path
changing $PATH

3. Running env
running the scripts with sh
running in bash

Am I missing something?

These scripts contain commands to control our consoles
which turn on channels, route audio, mute channels, etc
The scripts send data via udp to the console using /dev/udp
I have not had a problem with then in version 2.*
The scripts run fine in terminal as any user.

Thanks for any thoughts or help on this.

Tim Camp
WZEW-FM
Mobile, Al.
___
Rivendell-dev mailing list
Rivendell-dev@lists.rivendellaudio.org
http://caspian.paravelsystems.com/mailman/listinfo/rivendell-dev