Search Results

Search: Posts Made By: Priya Amaresh
5,363
Posted By Priya Amaresh
Grep mpath disk name from lsblk command
When I use lsblk | tail -1 | awk -F " " '{print $1}' command and if a disk is a multipath I get output as └─mpathe


But i need only mpathe to be grepped as output.. Please help.. But It works...
26,333
Posted By Priya Amaresh
ing:~ modinfo sch_netem modinfo: ERROR: Module...
ing:~ modinfo sch_netem
modinfo: ERROR: Module sch_netem not found.
ing:~

Actually kernel-modules-extra, iproute-tc packages are installed.. I guess this sch_netem is for ubuntu..
I am waiting...
26,333
Posted By Priya Amaresh
Thank you Neo :) But still same issue even if i...
Thank you Neo :) But still same issue even if i use 5% loss
I am using Rhel8.1
26,333
Posted By Priya Amaresh
NETEM - fq_codel and pfifo_fast change/add tc rule
HI,
I am trying to understand netem operation over Linux

when I issued tc show command i see as follows:
ing:~ tc qdisc show dev en1
qdisc mq 0: root
qdisc fq_codel 0: parent :18 limit 10240p...
Forum: Programming 04-03-2019
2,677
Posted By Priya Amaresh
it worked. THanks a lot :)
it worked. THanks a lot :)
Forum: Programming 04-02-2019
2,677
Posted By Priya Amaresh
this is python3
this is python3
Forum: Programming 04-02-2019
2,677
Posted By Priya Amaresh
Search or find a element inside list python
I have a list as follows:

[u'12:13-internet-wifi-primary', u'26:27-broadcom-wifi']


From this i need to grep the element using keyword as "primary" and return output as

...
823
Posted By Priya Amaresh
How to iterate a function untill last argument with any order of input?
HI

I need to get the function "kick" to get executed in any way the parameters are passed in to the function. The parameters are first stored in a dictionary

self.otherlist = {}
...
4,741
Posted By Priya Amaresh
It worked this way finally when i used sed...
It worked this way finally when i used sed command inside paramiko python..

grpRem = "sed -i -E 's/paste=used//g' /etc/gr.txt"

Its surprising that my try worked :)
4,741
Posted By Priya Amaresh
Yes, outside python code it works fine. And...
Yes, outside python code it works fine.
And inside python code I see the entire command is printed as output and the command is not getting executed as in the follwoing

sed -i -E "/paste=used//g"...
4,741
Posted By Priya Amaresh
sed command inside paramiko python
Hi

I am trying to execute a sed command inside paramiko which finds and deletes the particular string from a file

But sed command doesnt work inside paramiko python


machine=qwe
dssh =...
Forum: Programming 01-24-2017
1,491
Posted By Priya Amaresh
Edit a file using pexpect python
Hi

I am damn new to this python scripting
I have arrived till getting into the console of a machine using pexpect
Now I just wanted to know how to list/edit the contents of a file using pexpect...
918
Posted By Priya Amaresh
Compare lines between two files
I have two files
I need to compare these two files and take the lines that are common in both the files and consider the line present in second file for my further processing
I have used "Awk"...
1,095
Posted By Priya Amaresh
Date command
Hi

Is there any way to find out one day after from the current date

I know well the date command can get one day ago from current date

date +%Y:%m:%d -d "1 day ago"
2016:06:21

date...
1,097
Posted By Priya Amaresh
Any code using loop to compare each line of fileB...
Any code using loop to compare each line of fileB with fileA and print lines of filesA that doesnt exist at fileB
1,097
Posted By Priya Amaresh
Comparison of files
I have the requirement
I have two files

cat fileA
something
anythg
nothing
everythg

cat fileB
everythg
anythg


Now i shld use fileB and compare every line at fileA and get the output...
1,048
Posted By Priya Amaresh
This worked when I provide entire file as input ...
This worked when I provide entire file as input
But I need to store every grep value to a variable (i need to process each and every single line using loop)
1,048
Posted By Priya Amaresh
Separating words in a line
Hi
I have the following file
[root@teag8 ~]# cat red
it.d-state = 50988 41498 45 0 0 0
it.age_buffer= 1500
it.dir = 1


I need to grep lines that are present after "="
But...
1,110
Posted By Priya Amaresh
It worked .. Thanks :)
It worked .. Thanks :)
1,110
Posted By Priya Amaresh
Skip to next line if the variable is string
Hi

I have the follwoing requirement
I have a file as follows:

# cat priy
yyy.poweroff_cmd = /sbin/poweroff
hhh.powersave-nap = 1


When this file is provided as input, I first used "awk"...
6,642
Posted By Priya Amaresh
I have used date command to seed random value ...
I have used date command to seed random value

#!/bin/bash
c=1
RANDOM=$$$(date +%s)
expressions=(pink red white yellow purple)
while [[ $c -le 9 ]]; do
echo "The value of RANDOM is $RANDOM"...
6,642
Posted By Priya Amaresh
Random elements from array
Hi
I wanted to print random elements from an array at bash shell
I use the following code, but I always see first element getting printed

#!/bin/bash
c=1
expressions=(pink red white yellow...
Forum: IP Networking 02-17-2015
1,751
Posted By Priya Amaresh
IP and expect scripting
Hi

I am new to IP configuration and using expect script

I have a requirement like

I need to write a expect script that can ssh to a remote machine(linux1) using password which already has...
2,897
Posted By Priya Amaresh
sed is not overwriting a file
hi

i have a file as in follwoing:


cat apple.txt
Apple is a fruit
But this fruit is costly


Now I used the sed command and i see output as in following

[root@2 ~]# sed...
3,897
Posted By Priya Amaresh
HI Ravinder I am trying to write into a file...
HI Ravinder

I am trying to write into a file in the form of array.
Whereas the column attribute remains constant and row entries will be held.
I tried the following
declare -A matrix...
Showing results 1 to 25 of 126

 
All times are GMT -4. The time now is 07:54 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy