Icecast Streaming Media Server Forum Index Icecast Streaming Media Server
Icecast is a Xiph Foundation Project
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Centos 5 + Icecast + Tears

 
Post new topic   Reply to topic    Icecast Streaming Media Server Forum Index -> Icecast Server
View previous topic :: View next topic  
Author Message
tucker



Joined: 12 Mar 2009
Posts: 6

PostPosted: Thu Mar 12, 2009 10:43 pm    Post subject: Centos 5 + Icecast + Tears Reply with quote

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
View user's profile Send private message
karlH
Code Warrior
Code Warrior


Joined: 13 Jun 2005
Posts: 5476
Location: UK

PostPosted: Fri Mar 13, 2009 12:20 am    Post subject: Reply with quote

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
View user's profile Send private message Send e-mail Visit poster's website
tucker



Joined: 12 Mar 2009
Posts: 6

PostPosted: Fri Mar 13, 2009 1:49 am    Post subject: Reply with quote

no... no I didn't...

Other than that did I give it write access?
Back to top
View user's profile Send private message
jcr
Modérateur français
Modérateur français


Joined: 14 Apr 2006
Posts: 544
Location: France, Auvergne

PostPosted: Fri Mar 13, 2009 4:25 pm    Post subject: Reply with quote

Should be correct Smile

For those who don't want building their own centos icecast RPMs, I have a build for 5.2 x86_64.

http://www.lab-project.net/files/centos/icecast-2.3.2-5.x86_64.rpm

Source RPM is available at:

http://www.lab-project.net/files/centos/icecast-2.3.2-5.src.rpm
_________________
Epsilon Friends Radio Icecast Radio on CentovaCast admin panel. Icecast hosting
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
tucker



Joined: 12 Mar 2009
Posts: 6

PostPosted: Fri Mar 13, 2009 4:50 pm    Post subject: Reply with quote

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
View user's profile Send private message
karlH
Code Warrior
Code Warrior


Joined: 13 Jun 2005
Posts: 5476
Location: UK

PostPosted: Fri Mar 13, 2009 4:54 pm    Post subject: Reply with quote

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
View user's profile Send private message Send e-mail Visit poster's website
tucker



Joined: 12 Mar 2009
Posts: 6

PostPosted: Fri Mar 13, 2009 5:31 pm    Post subject: Reply with quote

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
View user's profile Send private message
jcr
Modérateur français
Modérateur français


Joined: 14 Apr 2006
Posts: 544
Location: France, Auvergne

PostPosted: Fri Mar 13, 2009 5:34 pm    Post subject: Reply with quote

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
View user's profile Send private message Visit poster's website MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic    Icecast Streaming Media Server Forum Index -> Icecast Server All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2002 phpBB Group
subRebel style by ktauber