Sponsored Content
Operating Systems Solaris Prustat throwing error only in zones not in global Post 303034548 by Sumanthsv on Monday 29th of April 2019 03:52:39 AM
Old 04-29-2019
Prustat throwing error only in zones not in global

Hi,

Prustat is throwing error only in zones. But it is working fine in global.
Code:
dtrace: invalid probe specifier
/*
** The following is a trimmed version of two seperate DTrace scripts:
**
** socketsnoop.d - snoop TCP network socket traffic by process.
**  This is intended to identify the process responsible
**  for network traffic. Written in DTrace (Solaris 10 build 63).
**
** iosnoop.d - A program to print I/O events as they happen, with useful
**      details such as UID, PID, inode, command, etc.
**      Written in DTrace (Solaris 10 build 63).
**
*/

#pragma D option quiet


/*
** --- TIMESTAMPS ---
*/
dtrace:::BEGIN {
        printf("B %d\n",timestamp);
        /* last is used as a timestamp to the disk request, OR,
           to the last disk completion. This is needed to avoid
           over counting disk times due to disk buffers (queues),
           however remains a minor simplification. */
        last = timestamp;
}
io:::done
{
        printf("D %d %d %d %d %s\n",
         this->suid,this->spid,this->delta,args[0]->b_bcount,
         this->scomm == 0 ? "." : stringof(this->scomm));
}


/*
** --- NETWORK ----
*/

/*
**  Store Write Values
*/
fbt:ip:tcp_output:entry
{
        self->uid = curpsinfo->pr_euid;
        self->pid = pid;
        self->comm = (char *)curpsinfo->pr_fname;
        self->size = msgdsize(args[1]);
        self->ok = 1;
}

/*
**  Store Read Values
*/
fbt:sockfs:sotpi_recvmsg:entry
{
        self->uid = curpsinfo->pr_euid;
        self->pid = pid;
        self->comm = (char *)curpsinfo->pr_fname;
        /* We track the read request (man uio), */
        self->uiop = (struct uio *) arg2;
        self->residual = self->uiop->uio_resid;
        /* The following ensures the type is AF_INET (sys/socket.h), */
        this->sonode = (struct sonode *)arg0;
        self->ok = (int)this->sonode->so_type == 2 ? 1 : 0;
}
fbt:sockfs:sotpi_recvmsg:return
/arg0 != 0 && self->ok/
{
        /* calculate successful read size */
        self->size = self->residual - self->uiop->uio_resid;
}

/*
**  Print output
*/
fbt:ip:tcp_output:entry, fbt:sockfs:sotpi_recvmsg:return
/self->ok/
{
        printf("N %d %d %d %s\n",self->uid,self->pid,
         self->size,stringof(self->comm));
        self->ok = 0;
        self->uid = 0;
        self->pid = 0;
        self->comm = 0;
        self->size = 0;
        self->residual = 0;
        self->uiop = 0;
}
: probe description dtrace:::BEGIN does not match any probes

Actually what the error is printing on screen is the code inside Prustat after _DATA_ line

Code:
uname -r

output on global and zone as below,
Global:5.11
zone:5.10

I have tried setting
Code:
limitpriv="default,dtrace_proc,dtrace_user"

to the zone. But still not working

TIA
 

8 More Discussions You Might Find Interesting

1. Solaris

Global Zones

I'm logged into a non-global zone server. How would I find out what the global zone server name is from there? (1 Reply)
Discussion started by: soupbone38
1 Replies

2. Solaris

Global zones - not allow log via SSH

Hi, I have Global zone and 2 users: root and app. I know password root and app. When a user app log - putty displays Access denied Using keyboard-interactive authentication. In file /etc/security/policy.conf I set CRYPT_DEFAULT=2a And in file /etc/ssh/sshd_config I set PermitRootLogin... (1 Reply)
Discussion started by: bieszczaders
1 Replies

3. Solaris

How to access ENV variables of non global zones in global zone???

Hi Guys, My requirement is I have file called /opt/orahome/.profile in non global zone. PATH=/usr/bin:/usr/ucb:/etc:/usr/sbin:/usr/local/bin:/usr/openwin/bin:. export PATH PS1="\${ORACLE_SID}:`hostname`:\$PWD$ " export PS1 EDITOR=vi export EDITOR ENV=/opt/orahome/.kshrc export ENV... (1 Reply)
Discussion started by: vijaysachin
1 Replies

4. Solaris

How to see global hostname by logging in non global zones?

Hi guru Could any one help me by letting me know, how to see global hostname by logging in non global zones Regards (2 Replies)
Discussion started by: girish.batra
2 Replies

5. Solaris

How to share/mount ZFS in two non-global zones?

Hi All, first time here. :o I need a some assistance with ZFS. I have two ZFS pools: zoneA/nfs_export zoneB/nfs_export Each dataset is mounted in a particular zone (zoneA and zoneB respectively). I have created a new dataset "zoneA/nfs_tmp" which I want to mount or share... (8 Replies)
Discussion started by: gabriel4
8 Replies

6. Solaris

cpu- requirements for non-global zones

Hello Admins, Does anyone has any idea on how to assign no. of cpu and memory to non-global zones on solaris 10..... We have few zones in our environment. We wanted to assign memory and no of cpu's ..(e.g. 4Gb / 2 CPU's) Thanks... (4 Replies)
Discussion started by: snchaudhari2
4 Replies

7. Solaris

Solaris 10 - rexplorer and Non-Global zones

Hi all - not really a problem as such, but just hoping someone can shed some light. We point rexplorer to multiple Global zones and it works as expected. However, each Non-Global zone get around a hundred of root su'ing to root messages, i.e.: SU 07/14 03:02 + ??? root-root SU 07/14 03:02 +... (5 Replies)
Discussion started by: dlam
5 Replies

8. Solaris

Solaris Global/Zones patching

Issue is : We have Solaris Global with 12 Zones and some have 15 Zones. All the OS version are10. Is it possible to apply patch at Zone level instead of patching at Global level? Please let me know. (10 Replies)
Discussion started by: baladelaware73
10 Replies
iosnoop(1m)							   USER COMMANDS						       iosnoop(1m)

NAME
iosnoop - snoop I/O events as they occur. Uses DTrace. SYNOPSIS
iosnoop [-a|-A|-Deghinostv] [-d device] [-f filename] [-m mount_point] [-n name] [-p PID] DESCRIPTION
iosnoop prints I/O events as they happen, with useful details such as UID, PID, block number, size, filename, etc. This is useful to determine the process responsible for using the disks, as well as details on what activity the process is requesting. Be- haviour such as random or sequential I/O can be observed by reading the block numbers. Since this uses DTrace, only users with root privileges can run this command. OPTIONS
-a print all data -A dump all data, space delimited -D print time delta, us (elapsed) -e print device name -i print device instance -N print major and minor numbers -o print disk delta time, us -s print start time, us -t print completion time, us -v print completion time, string -d device instance name to snoop (eg, dad0) -f filename full pathname of file to snoop -m mount_point mountpoint for filesystem to snoop -n name process name -p PID process ID EXAMPLES
Default output, print I/O activity as it occurs, # iosnoop Print human readable timestamps, # iosnoop -v Print major and minor numbers, # iosnoop -N Snoop events on the root filesystem only, # iosnoop -m / FIELDS
UID User ID PID Process ID PPID Parent Process ID COMM command name for the process ARGS argument listing for the process SIZE size of the operation, bytes BLOCK disk block for the operation (location. relative to this filesystem. more useful with the -N option to print major and minor num- bers) STIME timestamp for the disk request, us TIME timestamp for the disk completion, us DELTA elapsed time from request to completion, us (this is the elapsed time from the disk request (strategy) to the disk completion (iodone)) DTIME time for disk to complete request, us (this is the time for the disk to complete that event since it's last event (time between iodones), or, the time to the strategy if the disk had been idle) STRTIME timestamp for the disk completion, string DEVICE device name INS device instance number D direction, Read or Write MOUNT mount point FILE filename (basename) for I/O operation NOTES
When filtering on PID or process name, be aware that poor disk event times may be due to events that have been filtered away, for example another process that may be seeking the disk heads elsewhere. DOCUMENTATION
See the DTraceToolkit for further documentation under the Docs directory. The DTraceToolkit docs may include full worked examples with ver- bose descriptions explaining the output. EXIT
iosnoop will run forever until Ctrl-C is hit. AUTHOR
Brendan Gregg [Sydney, Australia] SEE ALSO
iotop(1M), dtrace(1M) version 1.50 Jul 25, 2005 iosnoop(1m)
All times are GMT -4. The time now is 08:03 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy