OPENVT(1)
๐ OPENVT(1) ๐
okay bestie so this is openvt from the General Commands Manual and it's genuinely one of those little tools that just does things. sit with me.
โจ NAME โจ
openvt โ start a program on a new virtual terminal (VT). that's it, that's the whole job, and she does it flawlessly ๐
๐ธ SYNOPSIS ๐ธ
openvt [-c vtnumber] [OPTIONS] [--] command
๐ฆ DESCRIPTION ๐ฆ
so here's the vibe: openvt goes looking for the first available VT, and then runs the command you gave it on that VT โ with whatever command options you passed along too. standard input, standard output and standard error all get pointed at that terminal. everything flows there. it's giving full immersion ๐
to find the command you asked for, it uses the current search path, aka $PATH. and if you don't specify a command at all? no worries, she just uses the environment variable $SHELL. iconic behavior honestly.
โจ OPTIONS โจ
-c,--console=VTNUMBERโ use this specific VT number instead of just grabbing the first available one. heads up though: you must have write access to the VT you're supplying or this is not gonna work, no cap.-f,--forceโ force open a VT without even checking whether it's already in use. living dangerously, love that for you ๐ฅ-e,--execโ directly execute the given command, without forking. this one is meant for use in/etc/inittab.-s,--switchโ switch over to the new VT when the command starts. the VT of the new command becomes the new current VT. main character energy, she takes the screen ๐-u,--userโ figure out the owner of the current VT and runloginas that user. suitable to be called byinit. shouldn't be used with-cor-l. also: this option refuses to pre-authenticate root and requires a process owned by the VT owner whose controlling terminal is the current VT.-l,--loginโ make the command a login shell. a-gets prepended to the name of the command to be executed.-v,--verboseโ be a bit more verbose. give us the tea โ-w,--waitโ wait for the command to complete. and if-wand-sare used together,openvtwill switch back to the controlling terminal when the command completes. she comes back, she always comes back ๐ซถ-V,--versionโ print program version and exit.-h,--helpโ show this text and exit.--โ end of options toopenvt.
โ ๏ธ NOTE โ ๏ธ
if openvt is compiled with a getopt_long() and you wanna set options for the command that's gonna be run, then you must supply the end-of-options -- flag before the command. no skipping this step bestie, the parser will simply not understand you.
the -u option uses login -f and therefore bypasses normal password authentication for the detected user. it is intended only for controlled init or keyboard-request configurations. use a normal authenticated login command when authentication is required. fr fr, don't get cute with this one ๐
๐ EXAMPLES ๐
openvt can be used to start a shell on the next free VT, by using the command:
openvt bash
to start the shell as a login shell, use:
openvt -l bash
to get a long listing you must supply the -- separator:
openvt -- ls -l
๐ HISTORY ๐
earlier, openvt was called open. it was written by Jon Tombs</> <jon@gtex02.us.es> or <jon@robots.ox.ac.uk>. and the -w idea is from "sam". a whole little origin story, we love a throwback ๐ง
๐ SEE ALSO ๐
chvt(1), deallocvt(1), vlock(1), login(1)
kbd ยท 24 October 2024 ยท that's the whole page bestie, go open a terminal and slay ๐โจ๐
๐ฆ where this page comes from
- arch rolling: kbd 2.10.0-1 ยท GPL-2.0-or-later
- fedora 43: kbd 2.8.0-4.fc43 ยท GPL-2.0-or-later
- fedora 44: kbd 2.9.0-4.fc44 ยท GPL-2.0-or-later
- opensuse-leap 16.0: kbd 2.7.1-160000.3.1 ยท GPL-2.0-or-later AND GPL-3.0-or-later
- opensuse-leap 16.0: kbd 2.7.1-160000.3.1 ยท GPL-2.0-or-later AND GPL-3.0-or-later
- opensuse-leap 16.0: kbd 2.7.1-160000.3.1 ยท GPL-2.0-or-later AND GPL-3.0-or-later
- opensuse-leap 16.0: kbd 2.7.1-160000.3.1 ยท GPL-2.0-or-later AND GPL-3.0-or-later
- Copyright 1994-95 Jon Tombs (jon@gtex02.us.es, jon@robots.ox.ac.uk)
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms