[Solved] apply 755 mode recursively


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting [Solved] apply 755 mode recursively
# 8  
Old 08-29-2011
Quote:
Originally Posted by Corona688
It is. The more and more CPU speed we have, the more and more wasteful programmers get, so it about balances out. If you can write just a little better, you can get really big gains.
I believe you are confusing programming versus what is a maintenance command... I agree that programming is getting lax, no doubt, as software gets more and more bloated over time ( I use a numerical finite difference program that has doubled in size over the past five years... Smilie )

However, The problem has nothing to do with software bloat, but rather ease of use versus a minor inconvenience of cpu time (which does not really affect the "end" user). Take a good look at any servers stats and you'll find it spends a lot of time idle. I would argue that as I type at the keyboard, I'm using less than 1% of one core out of six, with the other 5 cores being used up for a simulation I'm currently running (dynamic flow simulation)... I just ran my command over 10k of my simulation files in over 400 directories. It returned in ~5 seconds versus the ~2 seconds for the xarg version. So my point is... does 3 seconds really make a difference, particularly in the context of this thread?

I was asking why there seems to be a resistance to use built-in options for find where no bias should be found. xargs is a great and useful tool and if you actually issue command and wait for them, then I'd think the 3 seconds *may* be time saving... In my case, I tend to push command into the background, so I actually don't see a time savings at all (from the perception of my minds eye).

As for the 3 seconds, I think I waste more time lifting my cup of coffee... but then again, I do tend to drink slowly Smilie

Again, food for thought (or is it coffee?)
# 9  
Old 08-31-2011
Quote:
Originally Posted by wabard
However, The problem has nothing to do with software bloat, but rather ease of use versus a minor inconvenience of cpu time (which does not really affect the "end" user).
The difference between running chmod 75,000 times and running chmod 750 times is not "minor".
Quote:
Take a good look at any servers stats and you'll find it spends a lot of time idle.
Unless you install Wordpress. After that, any bit of extra CPU you can squeeze out is precious. Smilie (Adding one instance to a well-populated server bloated it from <0.1 avg load on PIII-600 to >.3 avg load on P4-2800!) IOW these tranquil conditions, while nice, shouldn't be assumed, lest you be the thing that makes them not true...

Also imagine using an expensive licensed OS where time literally is money, whether you're using the time or not. Wouldn't you want to extract as much work for the money as you could get? Many such servers operate under max loads continually.
Quote:
I would argue that as I type at the keyboard, I'm using less than 1% of one core out of six, with the other 5 cores being used up for a simulation I'm currently running (dynamic flow simulation)...
Congratulations on your 6 cores, if I had so much CPU time sitting idle I might try farming it out for something else...
Quote:
I just ran my command over 10k of my simulation files in over 400 directories. It returned in ~5 seconds versus the ~2 seconds for the xarg version.
A greater than 100% difference in performance sounds significant to me. Under a machine less fantastic than yours, the difference could easily become tedious.
Quote:
I was asking why there seems to be a resistance to use built-in options for find where no bias should be found.
Eh? You've proven yourself there's a difference, and obviously know why.

P.S: If you have -print0, try \+ instead of \; to get all the benefits of find+xargs without all the typing.
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Red Hat

[Solved] Redhat system is not booting in GUI mode

Hi Guys Required help in Redhat 6.1. After installation of Redhat 6.1 in VMware system is not going in GUI mode. please to solve the issue... Thanks... (5 Replies)
Discussion started by: deviltech
5 Replies

2. Solaris

[Solved] Can't get into single user mode - sulogin was disabled

Solaris 10 trying to patch and therefore want to do this from single user mode I do a init 0 get's me to ok> :) ok> boot -s I was a UK Sun Field Engineer for 10 years ..... I've used "boot -s " quite a bit ..... I get a console login , which I subsequently login into #who... (13 Replies)
Discussion started by: Martincorneuk
13 Replies

3. Solaris

DNS service is in maintenance mode. How to bring it back to online mode?

:confused: when i tried to look the status of DNS-client, it is in maintenance mode..... Please tell me how to bring it back to online mode...PLEASE TELL ME STEP BY STEP.... PLEASE... :wall: (2 Replies)
Discussion started by: vamshigvk475
2 Replies

4. Fedora

[SOLVED] How to be the ROOT through GUI mode in fedora 15

Whenevr i am trying to access ROOT file in Fedora 15 by double clicking, its showing I dont have enough permission to access it and its not showing the inside access... How to solve it?? (4 Replies)
Discussion started by: amisubha
4 Replies

5. Solaris

[Solved] How to change my default login mode????

Hi guys, I have just installed Solaris 10 x86. My system boots into graphical login by default, I want to have text login only, where can I change that. I tried to use the linux and bsd concept of editing /etc/inittab, and change the default value to 3, but that doesn't work in Solaris. Please... (6 Replies)
Discussion started by: gabam
6 Replies

6. Shell Programming and Scripting

sed : regular expression (hungry mode ?) solved

Hi there is something I don't understand with the repeated element. With the following command I have a weird output: :confused: while I thought the output would be I really don't understand why 2 "a" are skipped. Might someone explain please? (5 Replies)
Discussion started by: xib.be
5 Replies

7. Homework & Coursework Questions

changing permissions of a file whos name was passed to 755

Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted! 1. The problem statement, all variables and given/known data: Write a shell script that gives a passed file the "755" access permissions. The shell script should: Change... (5 Replies)
Discussion started by: anix007
5 Replies

8. Homework & Coursework Questions

changing permissions of a file whos name was passed to 755

Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted! 1. The problem statement, all variables and given/known data: Write a shell script that gives a passed file the "755" access permissions. The shell script should: Change... (0 Replies)
Discussion started by: anix007
0 Replies

9. AIX

dir 755 files 754

how to give permission in single command for .. All the sub-directories have to become permission 755 and files must be 754... do we have any option in chown .. or we have write script. any ideas please ... (2 Replies)
Discussion started by: govindarajan
2 Replies
Login or Register to Ask a Question