Win a copy of High Performance Python for Data Analytics this week in the Python forum!

Sharn Arora

Ranch Hand
+ Follow
since May 09, 2006
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Sharn Arora

Sorry.. forget to mention the server name. We are required to rotate access and log files for iPlanet Web Server.
14 years ago
Sorry.. forget to mention the server name. We are required to rotate access and log files for iPlanet Web Server.
14 years ago
Hi all,

Can someone please help me write script for below requirement:


Create a process/script that monitors that access file. When it gets close to 2GB automatically rotate the file.
After the logs are rotated, zip them up into the following format:
access.date-time.etcap35.gz
errors.date-time.etcap35.gz

the date-time portion should be formatted like this: 09Nov-0545AM (DDMon-HHMM)
After they have been zipped up, move them to another server named etcap37 into: /opt/webtrends/logs/RawLogs/etcap35-36 dir
(due to the ftp restrictions, you may have to ftp into your local account then have the 'wtrs' account move them to: /opt/webtrends/logs/RawLogs/etcap35-36)
14 years ago
Hello Ranchers,

Just out of curiousity.. wanna see how many ranchers believe in Destiny.. how many feel that everything in life is pre-destined.. When I say beliving in 'Destiny', it doesn't mean that we stop working hard and wait for some magic to happen.. but ofcourse it must have happened many a times during the course of our lives that we get something even if we don't deserve it or it may be the other way round that we have burned mid night oil to attain something but failed horribly due to some 'natural' element.. I'm sure lot of people have some stories to share..
14 years ago
Is it possible to include sender's address in mailTo attributes?

I understand that subject & body of email can be send as follows:

<A HREF="mailto:manish@simplygraphix.com?subject=Feedback for
webdevelopersnotes.com&body=The Tips and Tricks section is
great">Send me an email</A>

Can somebody please tell me how to include sender's email id as well?
Hi All,

This is my first post in the forum. Not sure if it fits in here but would love to have opinion of fellow ranchers.

I am working with a reputed indian based IT company from the past 4 years. I have spent these 4 years working on various platforms and technologies. Particularly, my inclination is towards J2EE platform.
My dilemma of 'Technical Vs Management Jobs' has arisen from a PL (Project Leader) role that I'm currently being offered. I'm a bit reluctant in accepting this role as I feel that it involves lot of management related activities that I'll be left with no time for technical stuff and I'm more interested in technical work.
I think if you are not comfortable in the kind of job you are doing, you will not be able to give your 100% and hence be inefficient. At the same time, I have seen the trend that if you accept such roles, its very good for your career growth. But it also makes me wonder, how good a PL can be if he is not technically sound and is not able to deliver the quality product to client. Can someone please take me out of this delimma.. Is this the right time to make a switch from technical to management stuff? What can be the possible alternatives. Thanks, in advance.
14 years ago
Hi All,

I have heard that only people from US and Canada can send their logo requests online; others have to manually sign the contract and send it to SUN to get the Logo whereas if I follow the link (SCJP Logo License Contract Web Page) in Edisandro's comment, I'm successfully able to accept the terms and conditions of the contract and submit the form. I'm from India and there is nothing stopping me to follow the online procedure. My questions are:

1. Has the online requisition activated for international users ? If not, how come I'm able to apply for logo online?
2. Am I following the correct procedure? If not, what is the correct procedure?
3. Do I still have to post the signed copy of contract to SUN?

Thanks, in advance for answers.
Hi Ranchers,

I have recently cleared SCJP and started prepartion for SCWCD. Can anyone direct me to SCWCD FAQ link? Thanks.
Right now I'm in a celebration mood
but soon will start preparing for SCWCD.. Thats what I'm inclined towards and thats what my job demands...

I wish best of luck to all SCJP aspirants !! My peice of advice is to code & practice as much as you can to strengthen your basics, Real exam will be then just a cake walk
14 years ago
Yippeeee Yuhoooooooo !!!

Finally Cleared SCJP 1.4 yesterday (3rd july) after 3 months long preparation !!

Thank you all ranchers!! It would not have been possible without this wonderful forum !!
14 years ago
Thanks for the explanation, Morten.
I'm convinced with your answer.. Just one doubt remaining. I feel, output should be unpredictable as we are not certain of the order of execution of Calulator & Reader threads. Lets assume if calculator thread finishes first (invoking implicit notifyAll in the end) before any of reader threads goes into waiting state for second time, in this case reader threads will continue waiting forever as the calculator thread has already terminated.

If the above assumption is true, we should get inconsistent output everytime we run the program. In my case, however, I'm getting the same output.

ps : I hope ques with ans dependent on thread schedular behavior are not asked in exam
I understand your example.

Can you please explain whats happening in my example. I beleive each of the three redaer threads are waiting for each other. Hence entering the deadlock. None of these will be able to complete and hence issue notifyAll.
Then how come output displays 'Control reaches here..' indicating that the threads terminated gracefully.
Output of the below program is

Waiting for calculation...
Waiting for calculation...
Waiting for calculation...
Total is: 4950
Total is: 4950
Total is: 4950
Control reaches here..
Control reaches here..
Control reaches here..

I understand the behavior of wait & notifyAll calls in general. My doubt is regarding second wait call that is invoked within the same run method. Once the calculator thread issues notifyAll, one of the reader thread wakes up (on the descretion of Thread Schedular) and prints total. After this, it again goes into the waiting state. My doubt is who notifies the thread again to wake it up and prints 'Control reaches here..'. It will be great if someone can detail the steps involved in the entire process. Thanks.

Are Drag & Drop type of questions asked in SCJP 1.4 exam ??