I want to know how we can add a new group in solaris. As per my understanding this is done by adding a new entry in /etc/groups file (or by using groupadd command which will also add the entry in the groups file). But when I use group command to see the groups to which I belong, it shows my userid... (7 Replies)
Can anybody plz help me to solve this puzzle?
amt=00002280674231
((amt = amt + 0)) # to remove leading zero's
echo $amt
prints -2014293065
but this works fine for numbers less than 2000000000.
Thanks
S (3 Replies)
Hi All
i need a add recored like
DateOfDU2=245,Time=00326 (in milli secounds )
DateOfDU2=245,Time=00347
DateOfDU2=245,Time=00258
DateOfDU2=246,Time=00325
DateOfDU2=246,Time=00408
DateOfDU2=246,Time=00257
DateOfDU2=247,Time=00037
DateOfDU2=247,Time=00417
DateOfDU2=247,Time=00420... (1 Reply)
I need some help with adding lines to file and substitute a pattern.
Ok I have a file:
#cat names.txt
name: John Doe
stationed: 1
name: Michael Sweets
stationed: 41
.
.
.
And would like to change it to:
name: John Doe
employed
permanently
stationed: 1-office (7 Replies)
Hello,
I have a main file with IP addresses like this:
Erisim var,100,172.17.241.5,4006,60,IS0799,TCP/IP
Erisim var,1003,172.17.140.4,4004,60,IS2156,TCP/IP
Erisim var,1004,172.17.140.5,4002,60,IS2636,TCP/IP
Erisim var,1005,172.17.140.5,4004,60,IS2436,TCP/IP
Erisim... (8 Replies)
Hi
I figured how to add my list of numbers. However how do I count so that after a certain number it lists the line.
Example:
12 test1
46 test2
195 test3
174 test4
634 test5
185 test6
94 test7
So basically add the numbers and when the addition reaches 300 or less
print the... (8 Replies)
Hi Admins,
I was told to add new ip,mask and gateway to my 3rd nic.so i prepared a plan doing the same via smitty. now i need to know do i plumb and unplumb before adding ip.
plz suggest
Regards
newaix (1 Reply)
Hi guys,
I am working with large data sets and often times realize that not all of the columns are aligned correctly (sometimes rows will be shifted). So when I try to do something like:
awk '{ if ($2 > 30 && $5 == $3){print}}' file > output
it won't really work since some of the rows... (2 Replies)
my shell script:
#!/bin/ksh
date +%d > /tmp/day.log
day=`tail /tmp/day.log`
############################
for example:
date +%d shows me 05
i want to add 14 days to 05 into my above script.
bc
5+15
19
but i am not sure how to put into above script. (5 Replies)
I have an array in an external file, "array.txt", which contains:
char *testarray={"Zero", "One", "Two", "Three", "Four", "Five", "Six", "Seven", "Eight", "Nine"};I want to be able to add an element to this array, and have that element display, whenever I call it, without having to recompile... (29 Replies)
Discussion started by: ignatius
29 Replies
LEARN ABOUT PLAN9
tc-cgroup
Cgroup classifier in tc(8) Linux Cgroup classifier in tc(8)NAME
cgroup - control group based traffic control filter
SYNOPSIS
tc filter ... cgroup [ match EMATCH_TREE ] [ action ACTION_SPEC ]
DESCRIPTION
This filter serves as a hint to tc that the assigned class ID of the net_cls control group the process the packet originates from belongs
to should be used for classification. Obviously, it is useful for locally generated packets only.
OPTIONS
action ACTION_SPEC
Apply an action from the generic actions framework on matching packets.
match EMATCH_TREE
Match packets using the extended match infrastructure. See tc-ematch(8) for a detailed description of the allowed syntax in
EMATCH_TREE.
EXAMPLES
In order to use this filter, a net_cls control group has to be created first and class as well as process ID(s) assigned to it. The follow-
ing creates a net_cls cgroup named "foobar":
modprobe cls_cgroup
mkdir /sys/fs/cgroup/net_cls
mount -t cgroup -onet_cls net_cls /sys/fs/cgroup/net_cls
mkdir /sys/fs/cgroup/net_cls/foobar
To assign a class ID to the created cgroup, a file named net_cls.classid has to be created which contains the class ID to be assigned as a
hexadecimal, 64bit wide number. The upper 32bits are reserved for the major handle, the remaining hold the minor. So a class ID of e.g.
ff:be has to be written like so: 0xff00be (leading zeroes may be omitted). To continue the above example, the following assigns class ID
1:2 to foobar cgroup:
echo 0x10002 > /sys/fs/cgroup/net_cls/foobar/net_cls.classid
Finally some PIDs can be assigned to the given cgroup:
echo 1234 > /sys/fs/cgroup/net_cls/foobar/tasks
echo 5678 > /sys/fs/cgroup/net_cls/foobar/tasks
Now by simply attaching a cgroup filter to a qdisc makes packets from PIDs 1234 and 5678 be pushed into class 1:2.
SEE ALSO tc(8), tc-ematch(8),
the file Documentation/cgroups/net_cls.txt of the Linux kernel tree
iproute2 21 Oct 2015 Cgroup classifier in tc(8)