jusupov.com

Computer Technology Blog

Archive for the ‘Open Source’ Category

How to install Darwin Streaming Server 6.0.3 on Ubuntu 8.04.2 Hardy

without comments

I couldn’t find any good tutorial on how to install Darwing Streaming Server on Ubuntu Hardy.

So let’s get started with a fresh install of 8.04.2 with all the updates.

  1. sudo apt-get update && sudo apt-get upgrade
  2. sudo apt-get install build-essential
  3. sudo addgroup –system qtss
    sudo adduser –system –no-create-home –ingroup qtss qtss
  4. cd /usr/local/src/
  5. Download the latest version at http://github.com/lstoll/dss/tree/master
  6. tar -xvf lstoll-dss-984a1365251f36ebf3f60f0d0175fa895a30b9a9.tar
  7. cd lstoll-dss-984a1365251f36ebf3f60f0d0175fa895a30b9a9/
  8. ./Buildit install
  9. cd DarwinStreamingSrvr6.0.3-Linux
  10. ./Install
  11. If you see Setup Complete! message, you are good to go. Logon to http://servername:1220/ using your browser. Username and password is the ones you entered at step 10.

Ok, now you have Darwin Streaming Server installed on your Ubuntu Hardy box.

Here’s a sample init file for DSS:
[sourcecode language="plain"]
#!/bin/sh
#
# chkconfig: 35 92 12
# description: Quicktime Streaming Media Server
#
# Slight tweak of file create by Larry Underhill 05/20/02
#
# init script to start up the quicktime (Darwin) streaming server
# tested on Redhat 7.2, Fedora Core 4 and CentOS-4.3

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

case "$1" in
start)
if test -r /var/lock/dssd
then
echo "Lockfile /var/lock/dssd exists. Server not started."
failure
else
echo "Starting Darwin Streaming Server: "
/usr/local/sbin/DarwinStreamingServer && touch /var/lock/dssd
echo "Starting DSS Admin Console: "
/usr/local/sbin/streamingadminserver.pl
echo "DSS and DSS Admin Console started…"
fi
;;

stop)
echo "Stopping Darwin Streaming Server: "
[ -f /var/lock/dssd ] || exit 0
echo "stopping…"
killall DarwinStreamingServer && killall streamingadminserver.pl
#ps ax | awk ‘{print $1" " $5}’ | awk ‘/DarwinStreamingServer/ {print $1}’ | xargs -r kill -9 && success || failure
#echo "Stopping DSS Admin Console: "
#ps ax | awk ‘/streamingadminserver.pl/ {print $1}’ | xargs -r kill -9  && success || failure
rm -f /var/lock/dssd
echo
;;

restart)
$0 stop
sleep 1
$0 start
;;

*)
echo "Usage: $0 [start|stop|restart]"
exit 1
esac
exit 0
[/sourcecode]
Save this file in /etc/init.d/dss

Make it executable chmod +x /etc/init.d/dss and make it auto start when booting:

update-rc.d dss defaults
Adding system startup for /etc/init.d/dss …
/etc/rc0.d/K20dss -> ../init.d/dss
/etc/rc1.d/K20dss -> ../init.d/dss
/etc/rc6.d/K20dss -> ../init.d/dss
/etc/rc2.d/S20dss -> ../init.d/dss
/etc/rc3.d/S20dss -> ../init.d/dss
/etc/rc4.d/S20dss -> ../init.d/dss
/etc/rc5.d/S20dss -> ../init.d/dss

Now that we have already installed DSS on Ubuntu Hardy box, next thing is how to broadcast mp3 and video through it. Well, that’s a next post coming up. :) Enjoy!

DSS Admin Console

DSS Admin Console

Written by Arstan

June 13th, 2009 at 2:08 am

Amazon EC2, Cloud Computing Getting Started

without comments

Amazon has this services where you can use virtual servers, either your custom or prebuilt publicly shared server images. The key point here is that Amazon has a lot of servers that can be used at any time.

So let’s get started. The first thing to do is sign up at Amazon EC2. I’ll be using Ubuntu on this.

You need Java JRE, do:

apt-get install sun-java5-jre

vim .bashrc

# Amazon Ec2
export EC2_HOME=~/.ec2
export PATH=$PATH:$EC2_HOME/bin
export EC2_PRIVATE_KEY=~/.ec2/pk-VGKIRWAKVSIEXEPVFQ2NSVQ4APUMYAC3.pem
export EC2_CERT=~/.ec2/cert-VGKIRWAKVSIEXEPVFQ2NSVQ4APUMYAC3.pem
export JAVA_HOME=/usr
type bash to reload your bash_rc

cd ~/.ec2

Amazon has this services where you can use virtual servers, either your custom or prebuilt publicly shared server images. The key point here is that Amazon has a lot of servers that can be used at any time.

So let’s get started. The first thing to do is sign up at Amazon EC2. I’ll be using Ubuntu on this.

You need Java JRE, do:

apt-get install sun-java5-jre

vim .bashrc

# Amazon Ec2
export EC2_HOME=~/.ec2
export PATH=$PATH:$EC2_HOME/bin
export EC2_PRIVATE_KEY=~/.ec2/pk-VGKIRWAKVSIEXEPVFQ2NSVQ4APUMYAC3.pem
export EC2_CERT=~/.ec2/cert-VGKIRWAKVSIEXEPVFQ2NSVQ4APUMYAC3.pem
export JAVA_HOME=/usr
type bash to reload your bash_rc

cd ~/.ec2

Amazon has this services where you can use virtual servers, either your custom or prebuilt publicly shared server images. The key point here is that Amazon has a lot of servers that can be used at any time.

So let’s get started. The first thing to do is sign up at Amazon EC2. I’ll be using Ubuntu on this.

You need Java JRE, do:

apt-get install sun-java5-jre

vim .bashrc

# Amazon Ec2
export EC2_HOME=~/.ec2
export PATH=$PATH:$EC2_HOME/bin
export EC2_PRIVATE_KEY=~/.ec2/pk-VGKIRWAKVSIEXEPVFQ2NSVQ4APUMYAC3.pem
export EC2_CERT=~/.ec2/cert-VGKIRWAKVSIEXEPVFQ2NSVQ4APUMYAC3.pem
export JAVA_HOME=/usr
type bash to reload your bash_rc

cd ~/.ec2

ec2-add-keypair arstan-keypair

Save those lines including  —–BEGIN RSA PRIVATE KEY—– and also  —–END RSA PRIVATE KEY—– lines.

sudo chmod 600 id_rsa-arstan-keypair

ec2-describe-images -o amazon This will show the server images that Amazon has for you. You can see ec2-describe-images -a to see all the server images you have access to.

ec2-run-instances ami-0459bc6d -k arstan-keypair

ec2-describe-instances will show you instances you are running.

Written by Arstan

September 24th, 2008 at 8:44 am

How to install libssh2 with PHP on CentOS 5 x86_64

with 3 comments

This post is just for archiving it, if you find it useful I’m glad!

If you are dealing with CentOS 5 x86_64 (Free version of RHEL5), try to install libssh2 for your PHP development you might fail in doing so.

So here’s a quick tip how to install libssh2 on X86_64 systems(I think i386 works just fine)

Edit: /usr/share/pear/pearcmd.php

Set: @ini_set(’memory_limit’, ‘16M’);

And try again!

Written by Arstan

January 19th, 2008 at 9:25 am

Posted in Linux, Open Source

How to reset MySQL root password in Ubuntu Linux

with 2 comments

In case you have forgotten your root password on your Ubuntu Linux, here’s a small tip on how to reset it.

$ sudo mysqld –skip-grant-tables &

$ mysql -u root mysql

$ mysql> UPDATE user SET Password=PASSWORD(’MyNewPasswordHere’) WHERE User=’root’;

$ mysql> FLUSH PRIVILEGES;

$ mysql> \q

$ sudo /etc/init.d/mysql restart

Now you can login using your new root password.

Written by Arstan

January 18th, 2008 at 9:58 am

Posted in Linux, Open Source

Sun to acquire MySQL

without comments

Jonathan Schwartz reports they are to acquire MySQL.

I am excited to see yet another good deal on Open Source projects, the fact that free software can do a good business.

Hopefully, they, Sun, will remain true to the Open Source spirit.

Written by Arstan

January 17th, 2008 at 10:21 am

Posted in Open Source