Works on command line but not in script; vncserver on solaris 10
Hi guys. My first post, so be gentle...
On my Solaris 10 machine vnc server is running. I need a command to extract most recent client session number (screen). So with:
Code:
I get what I need - just number 4. I've created few Firefox profiles called vnc1, vnc2, vnc3 and vnc4. Now I am trying to use above command to choose the profile name which correlates with session number in firefox command in /.vnc/xstarup:
Code:
However Firefox is not deriving correct profile name from the command. For this example it should be - firefox -P vnc4
Vnc is showing this error in the log file:
Code:
Code:
//.vnc/xstartup: syntax error at line 6: `)' unexpected
Could you please let me know what's wrong with firefox command syntax?
Cheers,
cp6uja
Hey there, I'm a total newbie unix guy here and just picking this stuff up. Have a very small script I put together that works fine from the command line but not once I put it in a cron job. Searched and found this thread and am wondering it it has something to do with setting variables, though the... (7 Replies)
Hi all,
The following script is fine when I work via command line
m=1
c=0
while
do
echo $m
gnokii --getsms IN $m > out.txt;
m=`expr $m + 1`;
cat out.txt >> message_log;
############
read first crap< <(sed -n '/Text:/{n;p;}' out.txt);
read message< <(sed -n '/Text:/{n;p;}'... (2 Replies)
Hi all-
I'm trying to search through some .gz log files to verify certain feeds have passed through our app.
I have a small script that I wrote in hopes that I could automate the checking but haven't been able to get the zgrep to work. When I copy it to the command line directly it works... (2 Replies)
When I run this code from the command line works
spinel.middlebury.edu:/u02/sct/banner/bandev2/middlebury/shl:DEV2$ ls ef*
eftseq.dat
spinel.middlebury.edu:/u02/sct/banner/bandev2/middlebury/shl:DEV2$ file_seq=$( < eftseq.dat) ... (1 Reply)
so in unix this command works works and shows me a list of directories
find . -name \*.xls -exec dirname {} \; | sort -u | > list.txt
but when i try running a perl script to run this command
my $query = 'find . -name \*.xls -exec dirname {} \; | sort -u | > list.txt';... (2 Replies)
Hey guys. Hopefully this is an easy one but having reference similar problems on the web I still can't fix it.
I am doing a recursive find and replace from a script. Of course I could just run the damn thing from the command line but it's bugging me now and want to get it working.
grep -rl... (4 Replies)
I have a really basic expect script which I call from php. I works fine when I run the php from the shell, but from the web it appears as if the output buffer gets chopped and never gets all of the contents.
php script: (runexpect.php)
<?php... (7 Replies)
I am working with a sh script on a solaris 9 zone (sol 10 host) that grabs information to build the configuration command line. the variables Build64, SSLopt, CONFIGopt, and CC are populated in the script. the script includes
CC=`which gcc`
CONFIGopt=' --prefix=/ --exec-prefix=/usr... (8 Replies)
OSX 10.9
I am building a script that evaluates the difference between 2 files. Here is a command that does not work transparently.
Running this command in Terminal yields great results; however when I put that line in a .sh script, I get the errors shown below. Am I doing something silly?
... (1 Reply)
I wish to replace "\\n" with a single white space.
The below does the job on command-line:
$ echo '/fin/app/scripts\\n/fin/app/01/sql' | sed -e 's#\\\\n# #g';
/fin/app/scripts /fin/app/01/sql
However, when i have the same code to a shell script it is not able to get me the same output:... (8 Replies)
Discussion started by: mohtashims
8 Replies
LEARN ABOUT LINUX
vncpasswd
vncpasswd(1) TightVNC vncpasswd(1)NAME
vncpasswd - set passwords for VNC server
SYNOPSIS
vncpasswd [file]
vncpasswd -t
vncpasswd -f
DESCRIPTION
The vncpasswd utility should be used to create and change passwords for the TightVNC server authentication. Xvnc uses such passwords when
started with the -rfbauth command-line option (or when started from the vncserver script).
vncpasswd allows to enter either one or two passwords. The first password is the primary one, the second password can be used for view-only
authentication. Xvnc will restrict mouse and keyboard input from clients who authenticated with the view-only password. The vncpasswd util-
ity asks interactively if it should set the second password.
The password file name defaults to $HOME/.vnc/passwd unless the -t command-line option was used (see the OPTIONS section below). The
$HOME/.vnc/ directory will be created if it does not exist.
Each password has to be longer than five characters (unless the -f command-line option was used, see its description below). Only the
first eight characters are significant. If the primary password is too short, the program will abort. If the view-only password is too
short, then only the primary password will be saved.
Unless a file name was provided in the command-line explicitly, this utility may perform certain sanity checks to prevent writing a pass-
word file into some hazardous place.
If at least one password was saved successfully, vncpasswd will exit with status code 0. Otherwise the returned status code will be set to
1.
OPTIONS -t Write passwords into /tmp/$USER-vnc/passwd, creating the /tmp/$USER-vnc/ directory if it does not exist, and checking the permis-
sions on that directory (the mode must be 700). This option can help to improve security when your home partition may be shared via
network (e.g. when using NFS).
-f Filter mode. Read plain-text passwords from stdin, write encrypted versions to stdout. One or two passwords (full-control and view-
only) can be supplied in the input stream, newline terminates a password. Note that in the filter mode, short or even empty pass-
words will be silently accepted.
SEE ALSO vncserver(1), Xvnc(1), vncviewer(1), vncconnect(1)AUTHORS
Original VNC was developed in AT&T Laboratories Cambridge. TightVNC additions were implemented by Constantin Kaplinsky. Many other people
participated in development, testing and support.
Man page authors:
Marcus Brinkmann <Marcus.Brinkmann@ruhr-uni-bochum.de>,
Tim Waugh <twaugh@redhat.com>,
Constantin Kaplinsky <const@tightvnc.com>
August 2006 vncpasswd(1)