Jump to content
  • 0

putty problem and athena-start


Kido

Question


  • Group:  Members
  • Topic Count:  127
  • Topics Per Day:  0.03
  • Content Count:  1445
  • Reputation:   163
  • Joined:  08/17/13
  • Last Seen:  

Hello, after a long way to migrate my eathena to rathena, among the way i got a bunch of errors

thanks to the help of everyone and of a friend, i managed to put online my server with putty, but with a plety of errors

i know (or i think i know) that i can correct that errors by myself, the big problem now is the following

 

I use linux centos

 

when i go ./athena-start start

the putty tells me that it does not exist, and that the thing has errors

here is a pic of the problem

fqjn.jpg

i have checked the paths and they are ok, also i have checked that those files exists

here is my athena-start script

 

#!/bin/sh

#source var/function
. ./function.sh
inst_launch_workaround

PATH=./:$PATH
print_start() {
  #    more << EOF
  echo "Athena Starting..."
  echo "            (c) 2013 rAthena Project"
  echo ""
  echo ""
  echo "checking..."
  #EOF
}

get_status(){
   PIDFILE=.$1.pid
   if [ -e ${PIDFILE} ]; then
    ISRUN=$(ps ax | grep $(cat ${PIDFILE}) | grep $1)
    PSRUN=$(echo "$ISRUN" | awk '{ print substr( $0, 0, 7) }')
   fi
   return $PSRUN
}

#cheking if already started, launch and mark in log
start_serv(){ 
  LOGFILE="log/$1.log"
  get_status $1
  echo "My logfile=${LOGFILE}"
  if [ -z ${PSRUN} ]; then
    exec ./$1&
    echo $! > .$1.pid
    echo "Server '$1' started at `date +"%m-%d-%H:%M-%S"`"
    echo "Server '$1' started at `date +"%m-%d-%H:%M-%S"`" >> ${LOGFILE}
  else
    echo "Can't start '$1', cause is already running p${PSRUN}"
    echo "Can't start '$1', cause is already running p${PSRUN}" >> ${LOGFILE}
  fi
}

#experimental
watch_serv(){
  LOGFILE=./log/$1.log
  ulimit -Sc unlimited

  while true; do
   get_status $1
   if [ -z ${PSRUN} ]; then
     $count=$count+1
     echo "server '$1' is down" >> ${LOGFILE}
     echo "restarting server at time at `date +"%m-%d-%H:%M-%S"`">> ${LOGFILE}
     exec ./$1&
     echo $! > .$1.pid   
     if [ $3 ] && [ $3 -lt $count ]; then break; fi
   else sleep $2    
   fi
  done
}

restart(){
  $0 stop
  for i in ${L_SRV} ${C_SRV} ${M_SRV}
    do
    while true; do
	get_status ${i}
	if [ ${PSRUN} ]; then echo "'${i}' is still running p${PSRUN} waiting end"; sleep 2;
        else break; fi
    done
  done
  $0 start
}

case $1 in
    'start')
        print_start
        check_files
	echo "Check complete."
	echo "Looks good, a nice Athena!"
	for i in ${L_SRV} ${C_SRV} ${M_SRV}
	    do
		start_serv $i
	    done
        echo "Now Started Athena."
;;
    'watch')
	for i in ${L_SRV} ${C_SRV} ${M_SRV}
	    do		
		watch_serv $i 10 3
	    done
 	echo "Now watching Athena."
;;	
    'stop')
	for i in ${L_SRV} ${C_SRV} ${M_SRV}
	    do
		PIDFILE=.${i}.pid
		if [ -e .{PIDFILE} ]; then
		    kill $(cat ${PIDFILE})
		    rm ${PIDFILE}
		fi
	    done
;;
    'restart')
         restart
;;
    'status')
	for i in ${L_SRV} ${C_SRV} ${M_SRV}
	do
		get_status ${i}
		if [ ${PSRUN} ]; then echo "'${i}' is running p${PSRUN}"; else echo "'${i}' seem down"; fi
	done
;;	
    *)
        echo "Usage: athena-start { start | stop | restart | status | watch }"
        read -p "Enter a valid option: " readEnterKey
		$0 $readEnterKey
;;
esac

 

well, that goes for my athena-start, however, here comes the interesting thing ._. i can run char, map and login by opening 3 putties (plural of putty (?)) and in each one run one different _sql, one for login-server_sql, one for char-server_sql and one more for map-server_sql

when i run them, i can't use any command, such 'exit', typing any command will end like if it was a text document, nothing happens ):

qsy.png

 

please help me to fix this out ):

 

how to fix my athena-start? (if need more information, i will add it)

how to fix putty? (if need more information, i will add it)

 

thanks again!

 

edit: forgot to mention that i use linux centos

Edited by Kido
Link to comment
Share on other sites

8 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  48
  • Topics Per Day:  0.01
  • Content Count:  410
  • Reputation:   29
  • Joined:  04/04/12
  • Last Seen:  

Try running the command ./configure && make clean && make sql.

 

I think the configure command is what affects that but I am not 100% sure.

  • Upvote 1
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  127
  • Topics Per Day:  0.03
  • Content Count:  1445
  • Reputation:   163
  • Joined:  08/17/13
  • Last Seen:  

i did that and i got these ):

the thing just does not advance

LkX5RgS.png

 

edit:

i went to that directory and found this

b9m0.png

it is trunk/conf/import

does it has something to do with it? thanks again! 

Edited by Kido
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  3
  • Topics Per Day:  0.00
  • Content Count:  707
  • Reputation:   168
  • Joined:  01/26/12
  • Last Seen:  

Hi Kido,

 

The compile had no issues, that is suppose to be the last line because it completed the compile. The /import folder is filled with empty files, so it has no effect; something you shouldn't worry about.

  • Upvote 1
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  127
  • Topics Per Day:  0.03
  • Content Count:  1445
  • Reputation:   163
  • Joined:  08/17/13
  • Last Seen:  

Hi Kido,

 

The compile had no issues, that is suppose to be the last line because it completed the compile. The /import folder is filled with empty files, so it has no effect; something you shouldn't worry about.

thanks! now that i know that i continued and the solution appeared, thanks again!

 

Try running the command ./configure && make clean && make sql.

 

I think the configure command is what affects that but I am not 100% sure.

 

i finally worked properly, in my last topic i tryied many things but they did not work, this solution made my day! finally athena-start is being recognized and lunchs perfectly, plus i can exit and leave online the server with the command 'exit', guess every commands afetr the lunch works fine, than you so much!

 

 

thanks again!

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  16
  • Topics Per Day:  0.00
  • Content Count:  737
  • Reputation:   216
  • Joined:  11/29/11
  • Last Seen:  

Kido, for the check_filess() not being recognize make sure you have function.sh into your folder, (s aethena-start using this file for this function).

For the cannot execute I suppose you needed chmod +x. so the "./configure && make clean sql" should have solve it ye.

  • Upvote 1
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  127
  • Topics Per Day:  0.03
  • Content Count:  1445
  • Reputation:   163
  • Joined:  08/17/13
  • Last Seen:  

Correct lady(you are not telling your gender so i will suppouse depending on your profile picture), afetr i did what michaelsoftman told me, ./athena-start had no permission, so i just chmod +x athena-start and everything went fine after that

i did not know about the check_files() not being recognize thing, thank you too, in the future i will not have this errores anymore :)

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  3
  • Topics Per Day:  0.00
  • Content Count:  22
  • Reputation:   2
  • Joined:  01/16/13
  • Last Seen:  

The way I was able to fix this was; instead of me trying to start all servers together using ./athena-start

 

I started them individually... so

 

./char-server start

 

./login-server start

 

./map-server start

  • Upvote 1
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  127
  • Topics Per Day:  0.03
  • Content Count:  1445
  • Reputation:   163
  • Joined:  08/17/13
  • Last Seen:  

this is a little old lol, thank you anyway for answering, i will consider that too o:

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...