11-25-2017
Aside comment: It's not recommended to have identical names for scripts, functions,variables, and / or commands.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi
All,
I have oracle 9i and 10g on unix. now i have 920.env and 1020.en file to set p respective enviornment.
when I excecute this commnad
. $HOME/920.env from the shell prompt it is working fine. and also same for 1020.env .
Now same command . $HOME/920.env i am putting in shell... (2 Replies)
Discussion started by: vishalpatel03
2 Replies
2. Shell Programming and Scripting
Dear all,
I am writing simple shell script.
#/bin/bash
ORACLE_HOME=/home/app/oracle/product/9.2.0
export ORACLE_HOME
export ORACLE_SID=DATX
$ORACLE_HOME/bin/sqlplus -s datadmin/password <<EOF
execute testproc;
exit;
EOF
~
~
In the above shell script, the oracle instance name is... (2 Replies)
Discussion started by: govindts
2 Replies
3. Shell Programming and Scripting
Trying to figure out why this works:
printpwd.pl
#!/usr/bin/perl
use CGI::Carp qw( fatalsToBrowser );
print "Content-type: text/html\n\n";
$A = system("pwd");
$A = `pwd`;
print "$A\n";
^^actually that works/breaks if that makes any sense.. i get the working directory twice but when... (5 Replies)
Discussion started by: phpfreak
5 Replies
4. Shell Programming and Scripting
Hi All,
I have writtern a shell script which has a sql query. I want to send the results of sql query to a shared area over a network.I also want to log the errors in a log file if the text file is not sent to shared area.
The results of sql query are spooled in TEMPFILE.
LOGFILE... (1 Reply)
Discussion started by: nsachin
1 Replies
5. UNIX for Dummies Questions & Answers
i wrote a shell program in Home Directory.
and i changed to other directory.
i want to try to execute shell script in Other Dir.
it is not executed.
how can i make this script to execute in other directory also??
Thanks,
Arun (11 Replies)
Discussion started by: arun508.gatike
11 Replies
6. Shell Programming and Scripting
Shell Scipt: temp.sh
su - <$username>
expect pass.exp
Expect script: pass.exp
#!/usr/bin/expect -f
# Login
#######################
expect "Password: " send "<$password>\r"
it comes up with Password: but doesnt take password passed throguh file. (2 Replies)
Discussion started by: bhavesh.sapra
2 Replies
7. Ubuntu
loop=y
while
do
clear
tput cup 5 15
echo -n "People Database"
echo -n "===================================="
tput cup 8 12
echo -n "L-Print Last Names"
tput cup 9 12
echo -n "F-Print First NAmes"
tput cup 10 12
echo -n "C-Print First Name, Last Name sorted by city"
tput cup 11 12... (3 Replies)
Discussion started by: Akhilaprabhakar
3 Replies
8. Shell Programming and Scripting
. /home/bscs6/.kshrc
set -x
monthy=`date +%m`
daty=`date +%d`
yeary=`date +%Y`
cd /home/bscs6/scripts
sqlplus sysadm/sysadm@SEGODI @lms_profile.sql
mv /home/bscs6/scripts/lmsprofile.log /home/bscs6/scripts/LMS_PROFILE_DUMP_$daty$monthy$yeary.txt
gives me the error below:
LMS_PROFILE.sh:... (3 Replies)
Discussion started by: malefho
3 Replies
9. Shell Programming and Scripting
Dear All,
I have script.
Dest=""
IFS='
'
for translation in $(echo $MY_MAP)
do
t1=$(echo $translation | cut -d"=" -f1)
t2=$(echo $translation | cut -d"=" -f2| cut -d"," -f1)
if
then
Dest=$UNX/$u_product_path/$u_study_path/$UNXTR/$t2
break;
... (4 Replies)
Discussion started by: yadavricky
4 Replies
10. Shell Programming and Scripting
Hi Guys,
I have one installer shell script which normally get from the dev team to install the app and it works fine for years (in IAX) the same installer/script iam trying to run in Linux 7.2 but it stuck somewhere which I cannot debug, can you help me to point out where it stuck .
here is the... (9 Replies)
Discussion started by: Riverstone
9 Replies
LEARN ABOUT HPUX
hostname
hostname(1) General Commands Manual hostname(1)
NAME
hostname - set or display name of current host system
SYNOPSIS
[name_of_host]
DESCRIPTION
The command displays the name of the current host, as given in the system call (see gethostname(2)). Users who have appropriate privileges
can set the hostname by giving the argument name_of_host; this is usually done in the startup script The name_of_host argument is
restricted to characters as defined in
The system might be known by other names if networking products are supported. See the node manager documentation supplied with your sys-
tem.
WARNINGS
If the name_of_host argument is specified, the resulting host name change lasts only until the system is rebooted. To change the host name
permanently, run the special initialization script (see
Many types of networking services are supported on HP-UX, each of which uses a separately assigned system name and naming convention. To
ensure predictable system behavior, it is essential that system names (also called host names or node names) be assigned in such a manner
that they do not create conflicts when the various networking facilities interact with each other.
The system does not rely on a single system name in a specific location, partly because different services use dissimilar name formats as
explained below. The and commands assign system names as follows:
+--------------+---------------+----------------+---------------------------+
|Node Name | Command | name Format | Used By |
+--------------+---------------+----------------+---------------------------+
|Internet name | hostname name | sys[.x.y.z...] | ARPA and NFS Services |
|UUCP name | uname -S name | sys | uucp and related programs |
+--------------+--------------+---------------+-----------------------+--|Node-+-Name-------|Command-------+ |name Format |Used By
| +--------------+--------------+---------------+-----------------------+ |Internet name |hostname name |sys[.x.y.z...] |ARPA and NFS Ser-
vices | |UUCP name |uname -S name |sys |uucp, related programs | +--------------+--------------+---------------+--------
--------------+
where sys represents the assigned system name. It is recommended that sys be identical for all commands and locations and that the
optional follow the specified notation for the particular ARPA/NFS environment.
Internet names are also frequently called host names or domain names (which are different from NFS domain names). Refer to hostname(5) for
more information about Internet naming conventions.
Whenever the system name is changed in any file or by the use of any of the above commands, it should also be changed in all other loca-
tions as well. Other files or commands in addition to those above (such as if used to circumvent for example) may contain or alter system
names. To ensure correct operation, they should also use the same system name.
System names are normally assigned by the script at start-up, and should not be altered elsewhere.
Setting a hostname of more than 64 bytes is possible only with the appropriate configuration options enabled. It is strongly recommended
that all related documentation be completely understood before setting a larger hostname. A hostname larger than 64 bytes can cause anoma-
lous or incorrect behavior in applications which use the command or the system function to access the name.
AUTHOR
was developed by the University of California, Berkeley.
SEE ALSO
uname(1), gethostname(2), sethostname(2), uname(2), hostname(5), nodehostnamesize(5).
hostname(1)