I am a newbie and what I have is a captured file of content. I want to be able to grab 2 pieces of data, multiple times and print them to the screen.
I created a script,
Code:
size=`du -sm`
size=`echo $size | sed 's/.$//'`
size1='30720'
if [ $size -gt $size1 ]
then
{
find /ask/tarballs -type f -name "*.tgz" -mtime +30 -exec ls -l {} \;
find /ask/tarballs -type f -name "*.tgz" -mtime +30 -exec rm -f {} \;
}
else
echo "Directory size doesnt exceed Threshold Limit"
fi
==============
which is in th
i create a file using dd command like this:
dd if=/dev/zero of=1g.dd bs=1M count=512 seek=512
when i run command ls 1g.dd, its size is 1G, run du 1g.dd, it's 512M.
there is a struct stat in c library to read file size, but it can only read out that 1G size, now how can i get that 512M size which is the real size of that file?
now the only way i know is to parse shell command du's output.
I am restoring Oracle datafile size of 1200GB. Datafile is read from backup piece size of 4000GB(4TB).
Note: As I monitored 4TB is processed totaly to read all blocks of my datafile.
I had several problems during restore:
Situation 1. There was period when after 2 hours restore was failing (Operation column in Netbackup Database Console was empty at that moment)
Situation 2.
Hi,
I am having the following codes which generates 24 files:
Code:
declare
begin
for i in 0..23 loop
EXECUTE IMMEDIATE 'create tablespace TSCGFCDR' ||to_char(sysdate,'DD')||'_'||to_char(i,'fm00')||
to_char(i+1,'fm00')||to_char(sysdate,'MONYY')||' DATAFILE '||
'''/ORADATA7/CRESTELDATA/TSCGFCDR'||to_char(sysdate,'DD')||'_'||to_char(i,'fm00')||
to_char(i+1
Hi
I have to find size of subdirectory and automate it in CRON.
Eg: parent directory name is NVBKP inside it there are several subdirectories
I want to get the size of recent two subdirectories.
I have tried ls -ltr diretory path | tail -2
But it is providing only size of the folder not the contents of that folder.
For eg if there are 5 subdirectories in NVBKP say
a
b
c
d
e
then i need compl
Write a function that accepts an int array and the array’s size as arguments. The function should create a new array that is twice the size of the argument array. The function should copy the contents of the argument array to the new array.
I tried to run on it, but it doesnt work.....what's going on??
please let me. thanks
#include "stdafx.h"
I am new to linux shell scripting and I am trying to set the following variable to get the size of a folder path passed in from keyboard. I keep getting an error saying invalid option. T
Can anyone tell me what I am doing wrong?
Using ubuntu 12.04,
$sudo vgdisplay
------------Volume group------------------
VG Name vol
Sysytem ID
Format lvm2
Metadata Areas 1
Metadata Sequence NO 1
VG Access read/write
VG Status resizable
MAX LV 0
Cur LV 0
Open LV 0
Max PV 0
Cur PV