Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
phddns_raspberry.tgz how to use in gentoo arm
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Unsupported Software
View previous topic :: View next topic  
Author Message
vastchen
n00b
n00b


Joined: 22 Apr 2016
Posts: 28

PostPosted: Fri Apr 22, 2016 2:12 am    Post subject: phddns_raspberry.tgz how to use in gentoo arm Reply with quote

hi everyone. i have raspberry pi2 install gentoo armv7a . i want to build a media wiki .but i in the Intranet so i want to install phddns_raspberry.tgz

down links:http://hsk.oray.com/download/download?id=25

install file oraynewph

Code:

#!/bin/sh

CURWDIR="$(cd $(dirname $0)&& pwd)"
ORAYNEWPH=`pidof oraynewph`
ORAYSL=`pidof oraysl`

start()
{
     if [ ! -f "/tmp/oraynewph_log" ]; then
   mkdir /usr/oray-app
   tar zxvf ./oraynewph.tgz  -C /usr/oray-app/
   rm -rf oraynewph.tgz
   mv ./parse  /usr/oray-app/parse
   mv ./oray_serve   /etc/init.d/oray_serve
   mv ./oraynewph /bin/oraynewph
   rm -rf  $CURWDIR/../phddns2
   touch /tmp/oraynewph_log
     fi
   kill $ORAYNEWPH
   kill $ORAYSL
   cd $CURWDIR/../
   update-rc.d oray_serve defaults
   /usr/oray-app/bin/oraynewph -s 0.0.0.0  &
   /usr/oray-app/bin/oraysl  -a 127.0.0.1 -p 16062 -s phsle01.oray.net:80 -d
   echo "Oraynewph start success !"
}
   
status()
{
   if [ -n "$ORAYNEWPH" ]; then
   /usr/oray-app/parse   
   fi
}
uninstall()
{
   kill $ORAYNEWPH
   kill $ORAYSL
   rm -rf /usr/oray-app   /tmp/oraynewph_log  /tmp/oraysl.status /etc/PhMain.ini /tmp/init.status /bin/oraynewph /etc/init.d/oray_serve /tmp/oraysl.pid

}
stop()
{
   kill $ORAYNEWPH
   kill $ORAYSL
   ######set reboot file(stop)#####
   update-rc.d  -f oray_serve remove
   echo "Oraynewph already stopped !"
}
reset()
{
   if [ -f "/etc/init.status" ]; then
      echo "Sure you want to reset it?(y/n)"
      read  userinfo
      if [ "$userinfo" =  "y" ]; then
         rm -rf /etc/init.status
         echo "reset success !"
      else
         echo "reset failed! try again"
      fi

   else
      echo "reset failed! try again"   
   fi
}
version()
{
   echo "Oray PeanutHull DDNS 1.0"
}
case "$1" in
       "start")
          start;;
      "status")
         status;;
   "uninstall")
           uninstall;;
   "stop")
      stop;;
       "reset")
      reset;;
     "-v")
        version;;
   *)
          usage;;
esac


Code:

oray seerver file
#!/bin/sh
### BEGIN INIT INFO
# Provides:          svn_serve
# Required-Start:    $all
# Required-Stop:     $all
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Short-Description: Start or stop the oraynewph
### END INIT INFO

case $1 in

start)
   /usr/oray-app/bin/oraynewph -s 0.0.0.0  &
   /usr/oray-app/bin/oraysl  -a 127.0.0.1 -p 16062 -s phsle01.oray.net:80 -d
   ;;
stop)
   killall oraynewph
   killall oraysl
   ;;
*)
echo "Usage: $0 (start|stop)"
;;

esac


parse file
Code:

 oray   
#!/bin/sh

USER_DATA="/tmp/oraysl.status"

SN=`head -n 2 $USER_DATA  | tail -n 1 | cut -d= -f2-`;
STATUS=`head -n 3 $USER_DATA  | tail -n 1 | cut -d= -f2-`;

echo  "RUNSTATUS= $STATUS"
echo  "SN= $SN"
echo  "LoginAddress= http://b.oray.com/"



I use this file install but no use。
here have eg. http://service.oray.com/question/2680.html
success run in raspberry pi (debain arm)
but i'can't no run on gentoo arm :cry:
I use root cp the file
Code:

mv ./parse  /usr/oray-app/parse
mv ./oray_serve   /etc/init.d/oray_serve
mv ./oraynewph /bin/oraynewph

it can start but can't getch the SN I guess parse file no work.
can somebody tell me how to change thouse file let it run in my raspberry pi2.
_________________
gentoo user
Back to top
View user's profile Send private message
Chiitoo
Administrator
Administrator


Joined: 28 Feb 2010
Posts: 1740
Location: Here and Away Again

PostPosted: Mon Apr 25, 2016 5:24 pm    Post subject: Reply with quote

Moved from Networking & Security to Unsupported Software.

This seems to be about software not currently available via Portage, so it will fit better here. It doesn't mean that no one will help with the issue, but it means it's not officially supported. :]
_________________
Kind Regards,
~ The Noob Unlimited ~

Sore wa sore, kore wa kore.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Unsupported Software 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