Dsy Network www | forum | my | didattica | howto | wiki | el goog | stats | blog | dona | rappresentanti
Homepage
 Register   Calendar   Members  Faq   Search  Logout 
.dsy:it. : Powered by vBulletin version 2.3.1 .dsy:it. > Didattica > Corsi N - Z > Sistemi operativi I > esercizio
  Last Thread   Next Thread
Author
Thread    Expand all | Contract all    Post New Thread    Post A Reply
Collapse
zigio
.amico.

User info:
Registered: Feb 2008
Posts: 23 (0.00 al dì)
Location:
Corso:
Anno:
Time Online: 7:07:01: [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged
esercizio

ciao ,qualcuno san come si risolve :

Trovare l'utente col file piu' recente nel sistema

io faccio così ma mi da errore
find / -type f -mtime -1 -exec ls -l \; |sort +5n | cut -f 1

16-09-2009 15:51
Click Here to See the Profile for zigio Click here to Send zigio a Private Message Find more posts by zigio Add zigio to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
mark
.grande:maestro.

User info:
Registered: Oct 2003
Posts: 783 (0.10 al dì)
Location:
Corso: F49
Anno: finito!
Time Online: 8 Days, 18:34:33 [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged
Re: esercizio

Originally posted by zigio
ciao ,qualcuno san come si risolve :

Trovare l'utente col file piu' recente nel sistema

io faccio così ma mi da errore
find / -type f -mtime -1 -exec ls -l \; |sort +5n | cut -f 1



hai dimenticato solo due cose

find / -type f -mtime -1 -exec ls -l {} \; |sort +5 -n | cut -f 1

__________________
Non ti perdere di coraggio se ti tocca lavorare molto e raccogliere poco.....

16-09-2009 16:24
Click Here to See the Profile for mark Click here to Send mark a Private Message Find more posts by mark Add mark to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
xSharKMaNx
un gioco della follia

User info:
Registered: Sep 2007
Posts: 1477 (0.22 al dì)
Location:
Corso: F49
Anno: Laureato
Time Online: 10 Days, 17:15:29 [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

code:
/find -type f -mtime -1 | xargs ls -ltT | head -1

__________________
Perché, mentre il manganello può sostituire il dialogo, le parole non perderanno mai il loro potere; perché esse sono il mezzo per giungere al significato, e per coloro che vorranno ascoltare, all'affermazione della verità. E la verità è che c'è qualcosa di terribilmente marcio in questo paese. (V)

I popoli non dovrebbero aver paura dei propri governi, sono i governi che dovrebbero aver paura dei popoli. (T.J)

16-09-2009 18:10
Click Here to See the Profile for xSharKMaNx Click here to Send xSharKMaNx a Private Message Find more posts by xSharKMaNx Add xSharKMaNx to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
zigio
.amico.

User info:
Registered: Feb 2008
Posts: 23 (0.00 al dì)
Location:
Corso:
Anno:
Time Online: 7:07:01: [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

grazie mille ragazzi ora mi torna tutto!

22-09-2009 15:34
Click Here to See the Profile for zigio Click here to Send zigio a Private Message Find more posts by zigio Add zigio to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
niko_2307
.precettore.

User info:
Registered: May 2008
Posts: 95 (0.01 al dì)
Location:
Corso:
Anno:
Time Online: 1 Day, 0:26:02: [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

Originally posted by xSharKMaNx
code:
/find -type f -mtime -1 | xargs ls -ltT | head -1



ciao, mi sapresti spiegare come mai xargs non passa output della pipe riga per riga?

29-10-2009 12:37
Click Here to See the Profile for niko_2307 Click here to Send niko_2307 a Private Message Find more posts by niko_2307 Add niko_2307 to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
xSharKMaNx
un gioco della follia

User info:
Registered: Sep 2007
Posts: 1477 (0.22 al dì)
Location:
Corso: F49
Anno: Laureato
Time Online: 10 Days, 17:15:29 [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

Originally posted by niko_2307
ciao, mi sapresti spiegare come mai xargs non passa output della pipe riga per riga?


xargs ti passa l'output della find come argomenti del comando successivo.

C'è sempre una dibattito tra xargs ed exec.

L'xargs se usato in maniera rischiosa, ad esempio in una find di grandi dimensioni, tende a schiantarsi.

Ciao

__________________
Perché, mentre il manganello può sostituire il dialogo, le parole non perderanno mai il loro potere; perché esse sono il mezzo per giungere al significato, e per coloro che vorranno ascoltare, all'affermazione della verità. E la verità è che c'è qualcosa di terribilmente marcio in questo paese. (V)

I popoli non dovrebbero aver paura dei propri governi, sono i governi che dovrebbero aver paura dei popoli. (T.J)

29-10-2009 16:37
Click Here to See the Profile for xSharKMaNx Click here to Send xSharKMaNx a Private Message Find more posts by xSharKMaNx Add xSharKMaNx to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
All times are GMT. The time now is 23:22.    Post New Thread    Post A Reply
  Last Thread   Next Thread
Show Printable Version | Email this Page | Subscribe to this Thread | Add to Bookmarks

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is ON
 

Powered by: vBulletin v2.3.1 - Copyright ©2000 - 2002, Jelsoft Enterprises Limited
Mantained by dsy crew (email) | Collabora con noi | Segnalaci un bug | Archive | Regolamento | Licenze | Thanks | Syndacate
Pagina generata in 0.058 seconds (68.70% PHP - 31.30% MySQL) con 24 query.