Unix OS

32K

Solutions

18K

Contributors

Unix is a multitasking, multi-user computer operating system originally developed in 1969 at Bell Labs. Today, it is a modern OS with many commercial flavors and licensees, including FreeBSD, Hewlett-Packard’s UX, IBM AIX and Apple Mac OS-X. Apart from its command-line interface, most UNIX variations support the standardized X Window System for GUIs, with the exception of the Mac OS, which uses a proprietary system.

Share tech news, updates, or what's on your mind.

Sign up to Post

what is the meaning of below command

zgrep 'CUSTOMERPASS' abcd.20180719.gz|grep -v 'Trials: 1'|less



Is there is single link, tutorial or video tutorial where i can find above kind of command
and
count command

more
less
grep
etc.

alll commonly used commands like above
why we need | before less?

Please advise
0
Cloud Class® Course: Microsoft Windows 7 Basic
LVL 12
Cloud Class® Course: Microsoft Windows 7 Basic

This introductory course to Windows 7 environment will teach you about working with the Windows operating system. You will learn about basic functions including start menu; the desktop; managing files, folders, and libraries.

how to find number of count in the unix logs for a grep search keyword say 'nullpointerexception on deviding 109418 with 0' please advise
0
Dear Experts,

On AIX I need to compare 2 files holding percentage space usage:

Format:

hn5691    :   /appli/oltb/apache/logs     72 %
hn5785    :   /appli/logs/REPORTING     38 %
...

If the percentage in the second file is 10% higher than in first file it should write that in a file (so that can be mailed).
Idea is to catch a looping process.

I'm not enough into awk to make it work, your help is appreciated.
I attach 2 files to work with.

Many thanks in advance.
W.
file2.txt
file1.txt
0
server times out

i have 15 production unix server instances to check logs same time

when i am on one monitor other monitor times out in every 15 minutes

if i type
tail -f logfile


does it still times out on me

i cannot change time out setting myself

just looking for some work around so that i do not have to enter username and password all over again
0
transactions search in unix logs


in the unix logs of transactions each transaction has bunch of values like

transaction_id|transaction_time|transaction_description|transaction_type| ......etc



if i want to display only the transactions that took more than say 30 minutes and whose transaction_type is "sell"

how do i frame my grep command for that

any sample queries, links, resources, sample video tutorials on this

Please advise
0
Hi, All.

I have an issue with IPTABLES rules. Here is below image shows my iptables rules. But i can not "telnet" port 2196. I've edited directly "/etc/sysconfig/selinux". And restarted iptables. Selinux disabled.

What am i doing wrong ?

0
what is the meaning of below command

less log123.log | grep -i nullpointerexception


why we use less and then grep on it

Please advise
0
in vi we can use /nullpointerexception to find that string right.

how to find how many occurrence of that string total and go to say 10th occurence line
please advise
0
when i open with winscp that opens old stale file compared to putty opening of same file say xyz.ccfg

i wonder why winscp does not show recent changs?

please advise
0
tail -f logfile.log


what is the meaning of above command.

i see logs rolling too fast.

is there is a way i can slow it down to see clearly slowly

any god tips, links, resources on how to debug production logs efficiently just using putty without any fancy costly tools?

please advise
0
Cloud Class® Course: SQL Server Core 2016
LVL 12
Cloud Class® Course: SQL Server Core 2016

This course will introduce you to SQL Server Core 2016, as well as teach you about SSMS, data tools, installation, server configuration, using Management Studio, and writing and executing queries.

At work I have a separate Unix password for unix systems. I reset my password
through a utility that gives me a temp password. Then I

sudo passwd

and change the password. I log out and log back in with the new password a few
seconds later. Success! But then a few hours later I try to log in with the new password
and it's no longer working and I have to go through the password reset process.

Anyone have a hunch what's going on?
0
I added this alias in my .bashrc file so it looks like this:

alias gh="grep \"hello world\" /folder/"

Open in new window


but when I type 'gh' into the command line I get the error:

> gh
bash: gh: command not found

Open in new window


Am I missing something?
0
i have files how can i get there size in gb
0
I created a script that will append a cron job if it's not in the crontab file, but the problem is the appended job will not work unless I edit the crontab file using crontab -e. Is there a way to refresh cron in AIX without killing the process?
0
Error in getting maxsize for diskgroup using vxassist


[root@test]# vxassist -g vxosdg  maxsize
VxVM vxassist ERROR V-5-1-18301  No volume can be created within the given constraints
[root@test]#

[root@test]# vxdg free
GROUP        DISK         DEVICE       TAG          OFFSET    LENGTH    FLAGS
testdg       98632345GDFE5F92480D7BB localhost_disk_0 localhost_disk_0 293601280 335450112 -
[root@test]#


[root@test]# vxassist -g testdg maxgrow data
Volume data can be extended by 335450112 to: 419336192 (204754Mb)
[root@test]# vxassist -g testdg make testvol 1g
VxVM vxassist ERROR V-5-1-18301  No volume can be created within the given constraints
[roo@test]#
0
difference between double and single quote in unix vs windows word document


1.
grep ‘Bean’ abc_1.log.20180627 //i am able to type this angular single quote in windows laptop in a word pad to save all commands to copy paste to unix box

2.
grep 'Bean' abc_1.log.20180627//why i cannot type this straight single quote character on windows laptop in a word pad to save all commands to copy paste to unix box?
3.
grep "Bean" abc_1.log.20180627


when i type below in word document of windows its shows as

grep ‘Bean’ abc_1.log.20180627
when i type below in putty/mputty of windows its shows as
grep 'Bean' abc_1.log.20180627



my purpose is to save all these unix queries to a word document so that next time i can copy paste from word document to putty and execute them without any tweaking to queries.

Please advise
grepCommands.png
0
I have a system HP-UX with rel 11.31

My problem is after delete lun from storage , i continue to see lun on system :

[root@accs2067]:/> scsimgr -p get_attr all_lun -a hw_path -a device_file -a wwid -a serial_number  | grep 43c
64000/0xfa00/0x13:/dev/rdisk/disk277:0x600507680c800172f00000000000043c:"020320005cbcXX00"

I've already removed the NO-HW with rmsf -vH <path hw> but with command upon i continue to see the lun

on system the lun correctly don't see :
[root@accs2067]:/> diskinfo /dev/disk/disk277
diskinfo: can't open /dev/disk/disk277: Invalid argument

Is possible erase by SCSI management ?
0
This is solaris-10 zone and it is repeated issue, I am seeing since sometime. Due to some reason, syslog is holding space and it keeps filling root file-system. I had to nullify process file of syslog and then space consumption of root was reduced from 19 GB to 2.7GB
bash-3.2# svcadm disable svc:/site/system/syslog-ng:default
bash-3.2# find /proc -type f -links 0 -ls | sort -n +6 | tail
find: stat() error /proc/11835/fd/43: No such file or directory
find: stat() error /proc/11820/fd/43: No such file or directory
find: stat() error /proc/11829/fd/43: No such file or directory
find: stat() error /proc/11821/fd/43: No such file or directory
find: stat() error /proc/11827/fd/43: No such file or directory
find: stat() error /proc/11825/fd/43: No such file or directory
find: stat() error /proc/11833/fd/43: No such file or directory
find: stat() error /proc/11826/fd/43: No such file or directory
find: stat() error /proc/11832/fd/43: No such file or directory
4213633025    4 -rw-------   0 root     root         2048 Apr 12 13:23 /proc/1222/fd/6
4213638852    4 -rw-------   0 root     root         2048 May 27 21:09 /proc/1222/fd/4
45240   73 -r--r--r--   0 adm      adm         73656 Apr 13 00:36 /proc/2140/fd/3
48364 17038328 --w-------   0 root     root     17434106014 Jun 21 16:41 /proc/3065/fd/6
48364 17038328 --w-------   0 root     root     17434106014 Jun 21 16:41 /proc/3065/fd/8
bash-3.2# ps -ef | grep 3065
    root  3065  1140   0   Apr 12 ?         645:53 

Open in new window

0
TSM 7.1 running on AIX 7.1 -Is there a way to restore only the folder structure and not the files within those directories? The restore of Oracle RMAN will populate the directory structures with the files. Thanks in advance!
0
Introducing Cloud Class® training courses
LVL 12
Introducing Cloud Class® training courses

Tech changes fast. You can learn faster. That’s why we’re bringing professional training courses to Experts Exchange. With a subscription, you can access all the Cloud Class® courses to expand your education, prep for certifications, and get top-notch instructions.

Dear Gurus,
I am using a curl command to transfer files as shown below . The reason is it needs to be sent to a particular port to enable tokenizing.
curl -k -v -T /export/home/flex/sample_files/Test_account_20180610.csv https://starserver.com:4443/webdav/Test_account_20180610.csv

Open in new window


This works fine.
The problem is that now I need to automate it using a scheduler.. but the file name suffix which is a date stamp keeps changing everyday.
Is there a way where I can give a curl command which just takes the file name irrespective of timestamp and put it in the webdav folder.
Something like this:

curl -k -v -T /export/home/flex/sample_files/Test_account_*.csv https://starserver.com:4443/webdav/Test_account_*.csv

Open in new window


SO that in teh webdav folder, I am getting the tokenised file with the name as that in the original location.

Please advise.

Thankyou very much.
0
i would like to know whether any additional slots are available for HBA card in Solaris node (2 Dual port or 1 Quad 4 port HBA). How to check free slots .

1. fcinfo hba-port showing all ports being used
2. luxadm -e port showing one path as not connected .

luxadm -e port
/devices/pci@400/pci@1/pci@0/pci@8/SUNW,qlc@0/fp@0,0:devctl        CONNECTED
/devices/pci@400/pci@1/pci@0/pci@8/SUNW,qlc@0,1/fp@0,0:devctl      CONNECTED
/devices/pci@400/pci@2/pci@0/pci@8/SUNW,qlc@0/fp@0,0:devctl        CONNECTED
/devices/pci@400/pci@2/pci@0/pci@8/SUNW,qlc@0,1/fp@0,0:devctl      NOT CONNECTED
0
Hello experts,

I'm very new to linux.

I'm trying to run the following commands on my Ubuntu machine:

COPY ./package.json /data/web-app
WORKDIR /data/web-app

Can someone please show me how to run these commands?

Cheers

Carlton
0
Hi everyone!
I am trying to do a few things in my bash script (script1.sh):  pass logicals/variables to my SAS program (program1.sas), execute SAS code (program1.sas), check with "errstat" for specific errors related to SAS code conditions that I set up in my SAS code, and also check with "logerrchk" SAS log file for any errors in the SAS log.  
I think most of the script is correct but I am not sure about both checking errors (errstat" and "logerrchk").

 Please note: variable/logicals (file1, file2, plog, and errstat) are also defined in the SAS program.  

 Please provide any suggestions or examples if you can.
 Here is what I have so far:

#!/bin/bash
#script1.sh

# Creating variables for directories
export DATADIR1=/root/alldirs/2018/data1
export DATADIR2=/root/alldirs/2018/data2
export DATADIR3=/root/alldirs/2018/data3
export PROGDIR1=/root/alldirs/2018/prog1

#Creating variables for data files that are used in program1.sas and final log file 
export file1=${DATADIR1}/sasdata1.sas7bdat
export file2=${DATADIR2}/sasdata2.sas7bdat
export plog=${DATADIR3}/sas_program.log

#executing SAS program
sas ${PROGDIR1}/program1.sas -log ${DATADIR3}/program1.log

#checking for errors in SAS log file
logerrchk=$?     
   if [[ "$logerrchk" !=0 ]]; 
   then 
       echo "--- Error: Abnormal end in program program1.sas. Check log file! ---" >> $plog
       exit 2
   else
       echo "--- Program1.sas run successfully! ---" >> $plog
   fi
  
#checking for specific errors 

Open in new window

0
hi am geting this error when starting my linux
linux
0
Unfortunately it is not clear to me how I can do it for change for client  the storage pool where data is stored,

What are the commands to be applied to tsm?

With upd copygroup give me this error :

tsm: TSM_7.1>upd copygroup SAP_PD ACTIVE PGT_DAI STANDARD Type=Archive destination=VCC_PRO_NEW
Session established with server TSM_7.1: AIX
  Server Version 7, Release 1, Level 1.100
  Server date/time: 06/05/18   16:13:12  Last access: 06/05/18   15:28:47

ANR1585E UPDATE COPYGROUP: Policy set ACTIVE cannot be modified.
ANS8001I Return code 3.

my policy

tsm: TSM_7.1>query policyset

Policy        Policy        Default       Description
Domain        Set Name      Mgmt
Name                        Class
                            Name
---------     ---------     ---------     ------------------------
SAP_PD        ACTIVE        SAP_MC        Policy set per ambiente
                                           SAP
SAP_PD        SAP_PS        SAP_MC        Policy set per ambiente
                                           SAP
0

Unix OS

32K

Solutions

18K

Contributors

Unix is a multitasking, multi-user computer operating system originally developed in 1969 at Bell Labs. Today, it is a modern OS with many commercial flavors and licensees, including FreeBSD, Hewlett-Packard’s UX, IBM AIX and Apple Mac OS-X. Apart from its command-line interface, most UNIX variations support the standardized X Window System for GUIs, with the exception of the Mac OS, which uses a proprietary system.