11-15-2016
it is about putting a pc into vpn. So can I add logging to bash script or something else to skip my typing everytime.
10 More Discussions You Might Find Interesting
1. AIX
Hi All:
I am a newbie.
I have shell script and bunch of java jar files and I want to give one single executable file (may be .bin).
Ex: I have test.sh, jar1.jar, jar2.jar. I have to make process.xxx
When we run "process.xxx" it will run the "test.sh" script which inturn uses jar1.jar and... (0 Replies)
Discussion started by: laxman123
0 Replies
2. UNIX for Dummies Questions & Answers
Hello,
I am very new to UNIX and I have been learning about writing scripts and making them executable. I created a script called myscript. It has three lines:
#! /bin/sh
# This is my first shell script
echo friendsjustfriends
Now I try to run it using the sh command and it works
Next I... (4 Replies)
Discussion started by: rohitx
4 Replies
3. UNIX for Dummies Questions & Answers
making a script in vi to create a shell script called wherearethey by entering the following script:
echo -n "Who are you looking for: "read userif then list=`w | grep $user | cut -c19-30` if then echo "The user $user is logged in from $list" else echo "The user $user is not logged in... (3 Replies)
Discussion started by: curtner
3 Replies
4. Shell Programming and Scripting
Guys I placed
#!path/awk -f
placed awk script
and used $1 to call 1st inputfile inside the script.
But some where I did mistake. Could you please help me run this script as executable
I forgot to mention I also used BEGIN before placing awk script. But nothing worked out.
Script
... (2 Replies)
Discussion started by: repinementer
2 Replies
5. UNIX for Dummies Questions & Answers
Hi guys, i'm trying to make a file called 'run-all-tests' executable but it is not letting me for some reason. I am presented with the following error: chmod: cannot access `./run-tests': No such file or directory
Basically i have a folder called ex3 and within that there are task folders:... (11 Replies)
Discussion started by: Shyamz1
11 Replies
6. UNIX for Dummies Questions & Answers
Hey guys, so I've been trying to write a bash script called runSorter.sh that runs an executable that also takes in some parameters and outputs the results to a text file. The executable, sorter, takes in a number parameter. I want to make it so that you can input as many number parameters into... (4 Replies)
Discussion started by: Duo11
4 Replies
7. Shell Programming and Scripting
Hello,
I have a perl program called snp_hwe.pl
I have another program called hwe_test.run which contains the following:
for file in *.inp
do
cp $file genotype_counts_c.txt
./snp_hwe.exe > $file'.res'
done
I want to change my perl program to an executable program while changing... (3 Replies)
Discussion started by: Homa
3 Replies
8. Shell Programming and Scripting
I wish to create an executable bash script that will run the following commands as root, that is, using sudo su
iptables-save | awk '/^
/ { print $1 }
/^:+ / { print $1 " ACCEPT" ; }
/COMMIT/ { print $0; }' | iptables-restoreMy first attempt at bash... (9 Replies)
Discussion started by: thixeqi
9 Replies
9. Shell Programming and Scripting
Hi all,
I'm new to Unix so just wanted some help.
I've been self learning and came accross a question online that I was trying. It is to make any shell script executable, the name of the file is to be made executable.
I would use nano and type in something like
#! /bin/bash
Chmod +x... (4 Replies)
Discussion started by: HelenaR
4 Replies
10. Shell Programming and Scripting
Is there a way to make this make itself executable?
Thanks. :-)
cat > somescript.sh << \EOF
#!/bin/bash
block_count=$(sudo tune2fs -l /dev/sda1 | awk '/^Block count:/ {print $NF}')
reserved_block_count=$(sudo tune2fs -l /dev/sda1 | awk '/^Reserved block count:/ {print $NF}')
perl -e... (4 Replies)
Discussion started by: drew77
4 Replies
LEARN ABOUT OSX
racoonctl
RACOONCTL(8) BSD System Manager's Manual RACOONCTL(8)
NAME
racoonctl -- racoon administrative control tool
SYNOPSIS
racoonctl reload-config
racoonctl show-schedule
racoonctl [-l [-l]] show-sa [isakmp|esp|ah|ipsec]
racoonctl flush-sa [isakmp|esp|ah|ipsec]
racoonctl delete-sa saopts
racoonctl establish-sa [-u identity] saopts
racoonctl vpn-connect [-u -identity] vpn_gateway
racoonctl vpn-disconnect vpn_gateway
racoonctl show-event [-l]
racoonctl logout-user login
DESCRIPTION
racoonctl is used to control racoon(8) operation, if ipsec-tools was configured with adminport support. Communication between racoonctl and
racoon(8) is done through a UNIX socket. By changing the default mode and ownership of the socket, you can allow non-root users to alter
racoon(8) behavior, so do that with caution.
The following commands are available:
reload-config
This should cause racoon(8) to reload its configuration file.
show-schedule
Unknown command.
show-sa [isakmp|esp|ah|ipsec]
Dump the SA: All the SAs if no SA class is provided, or either ISAKMP SAs, IPsec ESP SAs, IPsec AH SAs, or all IPsec SAs. Use -l to
increase verbosity.
flush-sa [isakmp|esp|ah|ipsec]
is used to flush all SAs if no SA class is provided, or a class of SAs, either ISAKMP SAs, IPsec ESP SAs, IPsec AH SAs, or all IPsec
SAs.
establish-sa [-u username] saopts
Establish an SA, either an ISAKMP SA, IPsec ESP SA, or IPsec AH SA. The optional -u username can be used when establishing an ISAKMP
SA while hybrid auth is in use. racoonctl will prompt you for the password associated with username and these credentials will be
used in the Xauth exchange.
saopts has the following format:
isakmp {inet|inet6} src dst
{esp|ah} {inet|inet6} src/prefixlen/port dst/prefixlen/port
{icmp|tcp|udp|any}
vpn-connect [-u username] vpn_gateway
This is a particular case of the previous command. It will establish an ISAKMP SA with vpn_gateway.
delete-sa saopts
Delete an SA, either an ISAKMP SA, IPsec ESP SA, or IPsec AH SA.
vpn-disconnect vpn_gateway
This is a particular case of the previous command. It will kill all SAs associated with vpn_gateway.
show-event [-l]
Dump all events reported by racoon(8), then quit. The -l flag causes racoonctl to not stop once all the events have been read, but
rather to loop awaiting and reporting new events.
logout-user login
Delete all SA established on behalf of the Xauth user login.
Command shortcuts are available:
rc reload-config
ss show-sa
sc show-schedule
fs flush-sa
ds delete-sa
es establish-sa
vc vpn-connect
vd vpn-disconnect
se show-event
lu logout-user
RETURN VALUES
The command should exit with 0 on success, and non-zero on errors.
FILES
/var/racoon/racoon.sock or
/var/run/racoon.sock racoon(8) control socket.
SEE ALSO
ipsec(4), racoon(8)
HISTORY
Once was kmpstat in the KAME project. It turned into racoonctl but remained undocumented for a while. Emmanuel Dreyfus <manu@NetBSD.org>
wrote this man page.
BSD
November 16, 2004 BSD