Premium Only Content

Linux Terminal Kurs Teil 3 - touch
#MiBaTech#MiBaHealthAndNutrition#MiBaFunAndGames
Willkommen zum dritten Teil meines Terminal-Kurses.
Heute wollen wir uns etwas genauer mit dem Befehl "ls" beschäftigen.
Der Befehl "ls" steht für "list files and directories" und zeigt euch an, was sich im jeweiligen Verzeichnis befindet.
Er kann auf verschiedene Weisen kombiniert werden.
touch <filename>
touch test1 test2
touch test{1..10}
touch test_{a..j}
stat filename
Die Informationen erhalten wir von stat
Im Folgenden finden Sie die Informationen, die wir über die Datei erhalten, wenn wir den Befehl stat ausführen.
Datei: Der Name der bereitgestellten Datei. Wenn es sich bei der bereitgestellten Datei um einen Symlink handelt, unterscheidet sich der Name.
Größe: Die Größe einer bestimmten Datei in Bytes.
Blöcke: Gesamtzahl der der Datei zugewiesenen Blöcke, die auf der Festplatte gespeichert werden sollen.
E/A-Block: Die Größe jedes zugewiesenen Blocks in Bytes.
Dateityp: Die Datei kann Folgendes sein: Normale Dateien, spezielle Dateien, Verzeichnisse oder symbolische Links.
Gerät: Gerätenummer im Hexadezimalformat.
Inode: Inode-Nummer der Datei.
Links: Anzahl der Hardlinks der Datei.
Zugriff: Zugriffsberechtigungen in den numerischen und symbolischen Methoden.
Kontext: Das Feld speichert den SELinux-Sicherheitskontext.
Zugriff: Der letzte Zeitpunkt, zu dem auf die Datei zugegriffen wurde.
Ändern: Der letzte Zeitpunkt, zu dem die Datei geändert wurde.
Änderung: Der letzte Zeitpunkt, an dem das Attribut oder der Inhalt der Datei geändert wurde.
Erstellt: Der Zeitpunkt, zu dem die Datei erstellt wurde.
File: The name of the provided file. If the provided file is a symlink, the name will differ.
Size: The size of a given file in Bytes.
Blocks: Total number of allocated blocks to the file to store on the hard disk.
IO Block: The size of every allocated block in bytes.
File type: The file may be of the following: Regular files, special files, directories, or symbolic links.
Device: Device number in hexadecimal format.
Inode: Inode number of the file.
Links: Number of hard links of the file.
Access: Access permissions in the numeric and symbolic methods.
Context: The field stores the SELinux security context.
Access: The last time at which the file was accessed.
Modify The last time at which the file was modified.
Change: The last time the at which file’s attribute or content was changed.
Birth: The time at which the file was created.
===============================================================================
Some of the options used with touch command are:
touch -a: change access time
touch -c: do not create files
touch -m: change modification time
touch -d <string> <filename> option to set a timestamp using a date string
touch -d tomorrow test
Change Access Time to Current
Use the -a tag to change a file's access time. The general syntax is:
touch -a <filename>
For example, to show a file's access time, run:
ls -lu
Next, change the access time for the file named test with:
touch -a test
Lastly, view the changed time by running:
ls -lu
===================================================================
touch -t <timestamp> <filename> Use specific time (instead of current time)
[[CC]YY]MMDDhhmm[.ss]
To break down this syntax, anything that is between the square brackets is optional. Below is what each cipher-like character stands for:
CC - the first two digits for a year
YY - the last two digits for a year
MM - the month
DD - the day
hh - the hour
mm - the minutes
ss - the seconds
touch -t 199901010000 test1
For example, to change the timestamp for a file called test to midnight January 1st, 1999, run:
==================================================================
Set File Timestamp Using Date String
The touch command uses the -d option to set a timestamp using a date string. The syntax is:
touch -d <string> <filename>
The date string is a flexible time format and accepts many different human-readable textual forms. Some examples include:
Calendar dates, such as 19 August 2020.
Time of day, such as 9:27pm or 8:02am.
Days of the week, such as Sunday, Monday, etc.
Relative time, such as 5 years ago, yesterday, next tuesday, etc.
For example, change the timestamp using the -d option to tomorrow:
================================
Playlist:
https://www.youtube.com/watch?v=uarQolcS5d8&list=PLq7y778vthUDlQdlLmzJPOJyLYXxBObzC&index=1
Timeline
0:46 df Befehl
1:38 du Befehl
3:10 free Befehl
Wenn euch das Video gefällt, würde ich mich über einen Like und ein Abo freuen. :)
MiBaTech,
stat, touch,touch -a,touch -t, Befehle, echo, cat, mkdir, rm, rmdir,
cp,mv,man,more,lees,sudo,chmod,top,htop,btop,which,whatis,version
Linux-Tutorials,dl,du,free
Ubuntu-Anleitung,
Linux-Befehle,
Linux-Grundlagen,
Linux-Distributionen
Linux-Installation,
Shell-Programmierung,
Open-Source-Software,
Linux-Anfänger,
Linux-Server-Konfiguration,
Terminal-Befehle,
Kommandozeilen-Tutorial,
Shell-Skripting,
Terminal-Tricks,
Befehlszeile für Anfänger,
Terminal-Fehlerbehebung,
Terminal-Hacks,
Linux-Kommandozeile,
Konsole verwenden,
Terminal-Shortcuts,
Audio- und Video-Bearbeitung,
Video schneiden,
Audio bearbeiten,
Videobearbeitungssoftware,
Tonmischung,
Videoeffekte,
Filmbearbeitung,
Videoproduktionstipps,
Audioaufnahme-Tutorial,
Video-Rendering,
Color Grading
-
LIVE
LindellTV
26 minutes agoMIKE LINDELL RESPONDS TO JIMMY KIMMEL "INDEFINITE SUSPENSION"
960 watching -
1:57:27
The Charlie Kirk Show
2 hours agoMegyn Kelly Remembers Charlie + Jimmy Kimmel Off the Air | 9.18.2025
147K52 -
LIVE
SternAmerican
23 hours agoElection Integrity Call – Thurs, Sept 18 · 2 PM EST | Featuring Rhode Island
75 watching -
4:22
Michael Heaver
2 hours agoLabour Face Brutal UK WIPEOUT
12 -
10:32
Faith Frontline
17 hours agoKenneth Copeland EXPOSED as America’s CREEPIEST Pastor Yet
612 -
4:33:50
Right Side Broadcasting Network
21 hours agoLIVE REPLAY: President Trump Holds a Press Conference with Prime Minister Keir Starmer - 9/18/25
52.8K38 -
1:01:35
The Rubin Report
3 hours agoJimmy Kimmel Humiliated as NY Post Exposes His Dark Reaction to Being Canceled
49.2K84 -
12:49
Clownfish TV
9 hours agoJimmy Kimmel Pulled OFF THE AIR for Charlie Kirk Comments?! | Clownfish TV
5.42K19 -
DVR
TheAlecLaceShow
2 hours agoJimmy Kimmel FIRED | ANTIFA Labeled Terrorist Org | Guest: Matt Palumbo | The Alec Lace Show
3.82K4 -
1:44:57
Steven Crowder
4 hours ago🔴 FAFO: Jimmy Kimmel's gets Chopped & The Left is Freaking Out
446K331