Can't Determine Error

sed: -e expression #1, char 31: unterminated `s' command

Does anyone know what might be causing this error message? It seems to also cause some strange empty files like sedTlU3nF and sedCrMjXk to be created. I get this error after adding some code to a script that is correct. The script runs ok even with the errors.


Similar Content



Error While Executing Ns2

i had added my own red.cc to ns2.34 when i run the tcl script it runs correctly, but after adding my own varible to red.cc and red.h the tcl script showing segmentation fault
please help me to remove the error

NS2 Nam And Trace Files Are Always Empty

Hi everybody,
I need help!
I wrote a script in which, a mobile node across the umts, the WIMAX and the WIFI coverage to test the vertical handover .
But the out.nam file and the trace one are always empty, the script is correct there is no errors !!!!
please help

Problem In Executing Script Through Crontab

Hi,
I have written one script which is connecting to the the daabase and generating one CSV, it is running fine when i ran it manually though it is throwing any warning but CSV is genearting and working fine but same script when i have configured in crontab not working and giving error, kindly help.

script contents:

#!/bin/bash
sqlplus -s /nolog << EOF
CONNECT plmc/plmb@whb
@csvgenerator.sql
end;
/
EOF
-----------------------------------
Script running successfully as below, though it is giving below message but running fine

$ sh test.sh
SP2-0734: unknown command beginning "sqlplus ct..." - rest of line ignored.

Session altered.
CSV geneartaed

Same Script giving error while triggering by crontab as below

$ sqlplus: not found

Duplicate Folder Creation While Using Mkdir In A Script

Hello,

I am setting up a linux server for gaming and I am using a script to update the files automatically and create a folder with a certain name.

Code:
# !/bin/bash

# A convenience function, to save us some work
update_server() {
	# Read the app id and the directory into a variable

	APP_ID=$1
	DIR=$2

	# Create the directory ( if it does not exist already )
	if [ ! -d "$HOME/$DIR" ]; then
		mkdir -p "$HOME/$DIR"
	fi

	# Uh-oh, it looks like we still have no directory. Report an error.
	if [ ! -d "$HOME/$DIR" ]; then
		# Describe what went wrong
		echo "ERROR! Cannot create directory $HOME/$DIR!"

		# Exit with status code 1 ( which indicates an error )
		exit 1
	fi

	# Call SteamCMD with the app ID we provided and tell it to install
	./bin/steamcmd.sh +login anonymous +force_install_dir "$HOME/$DIR" +app_update $APP_ID validate +quit
}

# Now the script actually runs update_server ( which we just declared above ) with the id of the application ( 4020 is Garry's Mod ) and the name of the directory we want the server to be hosted from:

update_server 4020 "gmodserver"

exit 0

When I run this script, it creates 2 folders on my server : gmodserver and gmodserver? There is no files downloaded in gmodserver. All the files are downloaded in gmodserver?

I looked for a few hours on how to solve this problem but I have no idea what the added ? might be so I am lost as to what to look for. Could you help me on figuring this out?

Thank you.

edit : I am using ubuntu 15.04 x64 if it makes a difference.

Value Comparison In Bash Shell Script

I need to compare a value with different fixed value. Below is the code concept I implemented in my bash script but its giving me error.
Here "a' is the nameserver value that I extract using command line from /etc/resolv.conf. I did not put command here.

#! /bin/bash
a=1.2.3.4

if [ $a == 1.2.3.4 || 5.6.7.8 || 8.9.1.4]
then
echo " You have correct ntpserver"
else
echo"wrong ntpserver"

fi

Am I comparing the value correctly or any suggestion?

Thank you

Problems With "error: Invalid Conversion From `const Char*' To `char*' "

Hi, I need some help. I tried to install obs-ns. Itīs based on ns2, but when I ran "make", the problem below appears... please I wish anybody would help me.


This is the error:

Code:
OBS/ns-2/integrated_agent.h: In constructor `BurstManager::BurstManager()':
OBS/ns-2/integrated_agent.h:86: warning: `BurstManager::bt_' will be initialized after
OBS/ns-2/integrated_agent.h:84: warning:   `int BurstManager::currburstsize_'
OBS/ns-2/integrated_agent.cc:66: warning:   when initialized here
OBS/ns-2/integrated_agent.cc: In member function `int BurstManager::nhops(nsaddr_t, nsaddr_t)':
OBS/ns-2/integrated_agent.cc:81: error: invalid conversion from `const char*' to `char*'   <------- this is the error 
OBS/ns-2/integrated_agent.cc: In member function `virtual void IPKTAgent::recv(Packet*, Handler*)':
OBS/ns-2/integrated_agent.cc:180: warning: unused variable 'ipkth'
/root/OBS/ns-allinone-2.31/tclcl-1.19/tclcl.h:150: error: `void Tcl::error(const char*)' is private
OBS/ns-2/integrated_agent.cc:185: error: within this context
OBS/ns-2/integrated_agent.cc:155: warning: unused variable 'hdr'
OBS/ns-2/integrated_agent.cc: In member function `void IPKTAgent::deBurst(Packet*)':
OBS/ns-2/integrated_agent.cc:192: warning: unused variable 'hdrip'
OBS/ns-2/integrated_agent.cc:194: warning: unused variable 'ch'
make: *** [OBS/ns-2/integrated_agent.o] Error 1


And this is the code of the program...


Code:
int BurstManager::nhops(nsaddr_t src,nsaddr_t des) {
  Tcl& tcl = Tcl::instance();
  sprintf(tcl.buffer(),"$ns nhops %d %d",src,des);
  tcl.eval();
  char *ni = tcl.result();   <------this is the line 81 
  return atoi(ni);
}

NS2 + Wimax, Erro Ao Executa O Script.

Hello, good guys am new to linux and also the issue of NS2, I need to run by the NS2 + WiMAX + LTE, the more I'm in trouble, I did this step by step http://gotoanswer.stanford.edu/?q=in...imax+in+ns2.35, installed straight over at the time I enter / ns2-35 / tcl / wimax and run a script with the $ ns wimax-script.tcl command it returns an error as shown in the image below, if anyone can help me I would be very grateful, hugs.

@obs.:I am using windows to make the simulation more the same error is repeated in linux.

https://dl-web.dropbox.com/get/Captu...K-UC2uSPQn_xtA

Snmpd Error!

I'm trying to get MRTG set up on Ubuntu 14.04 and cannot get snmpd to install correctly. Every time I try to install I get this error

/usr/sbin/snmpd: error while loading shared libraries: libnetsnmpagent.so.30: cannot open shared object file: No such file or directory
invoke-rc.d: initscript snmpd, action "start" failed.
dpkg: error processing package snmpd (--configure):
subprocess installed post-installation script returned error exit status 127
Processing triggers for ureadahead (0.100.0-16) ...
Errors were encountered while processing:
snmpd
E: Sub-process /usr/bin/dpkg returned an error code (1)

I've tried numerous possible fixes for this and have not found anything that works. Any help is greatly appreciated.

What Is The Best Way To Trap An Error In A Script

Hi All.

I am running a script that copies files to a USB disk.

What I would like to do is run another script if the USB disk get disconnected before the copying is done.

TIA.

Ant.

FileZilla Connection Issues

Hello,

I am having issues connecting to my linux box (opensuse 11.3) from my Window 7 sytem. I am using FileZilla. When I attempt to connect I get this error message

Status: Connecting to 192.168.198.205...
Response: fzSftp started
Command: open "Mike@192.168.198.205" 22
Command: Trust new Hostkey: Once
Command: Pass: *********
Error: Authentication failed.
Error: Critical error
Error: Could not connect to server

I am thinking it is a setup on issue on my Linux box but not sure what to change at this point. I must have some settings correct, because I am able to remote into my Linux box using FreeNX. Any help would be appreciated