View previous topic :: View next topic |
Author |
Message |
tucker
Joined: 12 Mar 2009 Posts: 6
|
Posted: Thu Mar 12, 2009 10:43 pm Post subject: Centos 5 + Icecast + Tears |
|
|
I feel I am so close yet so very far away...
I have Icecast installed on my centos 5.2 box... That went fine.. However I am having trouble configuring the icecast.xml file and user account persissions.
Here is what I have done.
-----------------------------------------------------------------------
A fresh centos 5.2 box as root:
yum install libvorbis-devel speex-devel libtheora-devel libxslt-devel curl-devel gcc rpm-build pam-devel openssl-devel net-snmp-devel
$ rpm -ivh http://downloads.xiph.org/releases/icecast/icecast-2.3.2-0.src.rpm
$ rpmbuild -bb /usr/src/redhat/SPECS/icecast.spec
$ rpm -ivh /usr/src/redhat/RPMS/i386/icecast-2.3.2-0.i386.rpm
$ useradd icecast
$ mkdir /var/log/icecast
$ chown icecast:icecast /var/log/icecast/
$ chmod 777 /var/log/icecast
icecast.xml -----
<icecast>
<limits>
<clients>100</clients>
<sources>2</sources>
<threadpool>5</threadpool>
<queue-size>524288</queue-size>
<client-timeout>30</client-timeout>
<header-timeout>15</header-timeout>
<source-timeout>10</source-timeout>
<burst-on-connect>1</burst-on-connect>
<burst-size>65535</burst-size>
</limits>
<authentication>
<source-password>MYPASS</source-password>
<relay-password>MYPASS</relay-password>
<admin-user>admin</admin-user>
<admin-password>MYPASS</admin-password>
</authentication>
<hostname>localhost</hostname>
<listen-socket>
<port>8000</port>
</listen-socket>
<listen-socket>
<port>8001</port>
</listen-socket>
<fileserve>1</fileserve>
<basedir>/usr/share/icecast</basedir>
<logdir>var/log/icecast</logdir>
<webroot>/usr/share/icecast/web</webroot>
<paths>
<adminroot>/usr/share/icecast/admin</adminroot>
<alias source="/" dest="/status.xsl"/>
</paths>
<logging>
<accesslog>access.log</accesslog>
<errorlog>error.log</errorlog>
<loglevel>3</loglevel>
<logsize>10000</logsize>
</logging>
<security>
<chroot>0</chroot>
<changeowner>
<user>icecast</user>
<group>icecast</group>
</changeowner>
</security>
</icecast>
------------------
Then I:
$ su icecast
$ icecast -c /etc/icecast.xml -b
I get:
FATAL: could not open error logging (var/log/icecast/error.log): Permission denied
FATAL: could not open access logging (var/log/icecast/access.log): Permission denied
FATAL: Could not start logging
Any help would add years to my life... Thanks! |
|
Back to top |
|
|
karlH Code Warrior
Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Fri Mar 13, 2009 12:20 am Post subject: |
|
|
you do know that you are missing a / before var
In any case, icecast requires write access to the directory used for logs.
karl. |
|
Back to top |
|
|
tucker
Joined: 12 Mar 2009 Posts: 6
|
Posted: Fri Mar 13, 2009 1:49 am Post subject: |
|
|
no... no I didn't...
Other than that did I give it write access? |
|
Back to top |
|
|
jcr Modérateur français
Joined: 14 Apr 2006 Posts: 544 Location: France, Auvergne
|
|
Back to top |
|
|
tucker
Joined: 12 Mar 2009 Posts: 6
|
Posted: Fri Mar 13, 2009 4:50 pm Post subject: |
|
|
I now have my server running... however when I start it I get:
WARNING: Can't change user id unless you are root.
The server runs but thats what I get. Am I starting it wrong? Should I do something different? What would the best why to start it on boot safely (as the icecast user)? |
|
Back to top |
|
|
karlH Code Warrior
Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Fri Mar 13, 2009 4:54 pm Post subject: |
|
|
not a problem really. In the xml you have said to change to the icecast user but as you are already running as a non root user so changing to that account is not possible. Personally I would say remove the changeowner from the xml and start icecast as the intended user.
karl. |
|
Back to top |
|
|
tucker
Joined: 12 Mar 2009 Posts: 6
|
Posted: Fri Mar 13, 2009 5:31 pm Post subject: |
|
|
So I would put it back to:
<security>
<chroot>0</chroot>
<!--
<changeowner>
<user>icecast</user>
<group>icecast</group>
</changeowner>
--<
</security>
How would I start icecast when the server boots then? |
|
Back to top |
|
|
jcr Modérateur français
Joined: 14 Apr 2006 Posts: 544 Location: France, Auvergne
|
Posted: Fri Mar 13, 2009 5:34 pm Post subject: |
|
|
well tucker, if you intend to use a startup script, such as in RPM build, this changeowner matters. But if you start icecast from a standard user account, ownership will fail to change.
This doesn't matter at all as you gavec world writable rights to logs. _________________ Epsilon Friends Radio Icecast Radio on CentovaCast admin panel. Icecast hosting |
|
Back to top |
|
|
|