Solved

Need to get Fedora/Linux Media Server using uShare working with Xbox 360

Posted on 2009-05-10
2
1,182 Views
Last Modified: 2013-12-06
Guys,

I have Fedora 10 installed on my laptop. I am planning to install it on my Home PC but I thought I would test uShare on my laptop first.

I have installed uShare and configured the sudo gedit /etc/ushare.conf  file.


http://www.liamm.com/tech/how-toxbox-360-media-server-in-linux

So it looks like this;

# /etc/ushare.conf
# uShare UPnP Friendly Name (default is 'uShare').
USHARE_NAME=VIDEOSERVER

# Interface to listen to (default is eth0).
# Ex : USHARE_IFACE=eth1
USHARE_IFACE=eth0

# Port to listen to
USHARE_PORT=49153

# Port to listen for Telnet connections
USHARE_TELNET_PORT=1337

# Directories to be shared (space or CSV list).
# Ex: USHARE_DIR=/dir1,/dir2
USHARE_DIR=/home/user/xbox360

# Use to override what happens when iconv fails to parse a file name.
USHARE_OVERRIDE_ICONV_ERR=yes

# Enable Web interface (yes/no)
ENABLE_WEB=yes

# Enable Telnet control interface (yes/no)
ENABLE_TELNET=no

# Use XboX 360 compatibility mode (yes/no)
ENABLE_XBOX=yes

# Use DLNA profile (yes/no)
# This is needed for PlayStation3 to work (among other devices)
ENABLE_DLNA=yes

When I use the command sudo /etc/init.d/ushare start
i should get * Starting uShare UPnP A/V & DLNA Media Server: ushare
...done.
instead I get 'starting share ... ok' - not sure if that is just the same outcome.

Ok, the next steps are to do this http://your.servers.ip.address:49153/web/ushare.html - done that and it works.

This is where it gets a bit strange;

When I try to edit this file ; sudo gedit /etc/init.d/ushare
I am supposed to do this

Find the following lines

start-stop-daemon --start --quiet --background --oknodo \
--make-pidfile --pidfile $PIDFILE \
--exec $DAEMON -- $USHARE_OPTIONS

And change them to

start-stop-daemon --start --quiet --background --oknodo \
--make-pidfile --pidfile $PIDFILE \
--exec $DAEMON -- $USHARE_OPTIONS --xbox

However, in my file I can't find any of these lines.

Mine looks like this ;

#!/bin/sh
#
# ushare            This shell script takes care of starting and stopping ushare.
#
# chkconfig: - 75 25
# description:      uShare UPnP A/V Media Server.
#

# Source function library.
. /etc/rc.d/init.d/functions

# Source networking configuration.
. /etc/sysconfig/network

# Check that networking is up.
[ ${NETWORKING} = "no" ] && exit 0

OPTIONS=""
prog=ushare
DESC="UPnP A/V Media Server"

[ -r "/etc/ushare.conf" ] && . /etc/ushare.conf
# abort if no shared directory is defined
[ -z "$USHARE_DIR" ] && exit 0


start() {
      echo -n $"Starting $prog: "
      daemon --user ushare $prog -d -D
      RETVAL=$?
      echo
      [ $RETVAL -eq 0 ] && touch /var/lock/subsys/$prog
}

stop() {
      echo -n $"Stopping $prog: "
      killproc $prog
      RETVAL=$?
      echo
      [ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/$prog /var/run/ircd.pid
}

reload() {
      echo -n $"Reloading $prog: "
      killproc $prog -HUP
      RETVAL=$?
      echo
}

# See how we were called.
case "$1" in
  start)
      start
      ;;
  stop)
      stop
      ;;
  status)
      status $prog
      RETVAL=$?
      ;;
  restart)
      stop
      start
      ;;
  condrestart)
      if [ -f /var/lock/subsys/$prog ]; then
        stop
        start
      fi
      ;;
  reload)
      reload
      ;;
  *)
      echo $"Usage: $prog {start|stop|restart|condrestart|reload|status"
      exit 1
esac

exit $RETVAL

When I start my Xbox 360, it does not show my Laptop.

Sorry for the long post but I though I would put as much info in as I can.

If you need the step by step guide to this here it is
http://www.liamm.com/tech/how-toxbox-360-media-server-in-linux

Thank you for your help
0
Comment
Question by:deepslalli
2 Comments
 
LVL 8

Accepted Solution

by:
thetmanvn earned 500 total points
ID: 24349254
Hi, deepslalli

There's difference because the tutorial you did is for Ubuntu, and you are Fedora so the init script has little difference.

You add --xbox after -d -D as below and test it

start() {
      echo -n $"Starting $prog: "
      daemon --user ushare $prog -d -D --xbox
      RETVAL=$?
      echo
      [ $RETVAL -eq 0 ] && touch /var/lock/subsys/$prog
}
0
 

Author Closing Comment

by:deepslalli
ID: 31623703
Fantastic response and very clear to understand - worked like a dream!!
0

Featured Post

Highfive Gives IT Their Time Back

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

The purpose of this article is to demonstrate how we can upgrade Python from version 2.7.6 to Python 2.7.10 on the Linux Mint operating system. I am using an Oracle Virtual Box where I have installed Linux Mint operating system version 17.2. Once yo…
The purpose of this article is to demonstrate how we can use conditional statements using Python.
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now