User Profile
Collapse
-
perl -pe 'chomp;print "\n" if $i++ && m/Total Number Of Inputs/;$_=(split/:/)[1];END {print "\n"}' report.txt -
I am not sure if this is the cause, but try a different encoding. MIME "should" be accepted by all mail servers.
http://us.php.net/function.mail for examples on sending HTML email....Last edited by zmbd; Sep 8 '18, 05:11 AM. Reason: [z{redacted personal information per request and site policy}]Leave a comment:
-
This code will give you the "LAST" directory listed in the current directoryCode:find . -type d -prune -exec ls -rt {} \; |tail -1
depending on your OS you the -prune option may be -maxdepth 1 instead
Code:find . -type d -maxdepth 1 -exec ls -rt {}\;|tail -1Leave a comment:
-
if you need them to be viewed as 08 and 09 you can do your calculations with the decimal equivalents 0 - 9 and use printf to display them with the leading 0 (zero)Leave a comment:
-
The '0' in 0764 is for the use of "sticky bit", "setuid", "setgid" etc...
here is how that bit is set
4 - setuid
2 - setgid
1 - sticky bit
setuid will yield a file that will be executed as the "owner" regardless of the user that executes the file
setgid will yield the same as setuid but with "group" instead of owner.
...Leave a comment:
-
here is sample code to get memory information from solaris in C
...Code:#include <stdio.h> #include <unistd.h> int main() { long numPages, pageSize, freePages, totalSize, totalUsed, totalFree; numPages = sysconf(_SC_PHYS_PAGES)/1024; pageSize = sysconf(_SC_PAGESIZE)/1024; freePages = sysconf( _SC_AVPHYS_PAGES)/1024; totalSizeLeave a comment:
-
using the nslookup command (windows or UNIX) you can get this information.
here is a quick sample script for UNIX (nslookup-dmp.ksh)
usage will be nslookup-dmp.ksh {domain} i.e. yourname.com
...Code:#!/bin/ksh /bin/echo "The Internet Address of $1..." /bin/nslookup -q=A $1 /bin/echo "The canonical name for alias for $1..." /bin/nslookup -q=CNAME $1 /bin/echo "The host CPU and
Leave a comment:
No activity results to display
Show More
Leave a comment: