DBIPROXY(1)

πŸ’… DBIPROXY(1) πŸ’…

okay so bestie, welcome to the dbiproxy manual page β€” that's the perl-y little proxy server situation for the DBD::Proxy driver, and yes we're gonna get through the whole thing together 🫢


✨ NAME ✨

dbiproxy β€” a proxy server for the DBD::Proxy driver. that's the whole vibe. main character proxy energy πŸ‘‘


🌸 SYNOPSIS 🌸

dbiproxy <options> --localport=<port>

literally just that. options, then a port. slay.


πŸ¦‹ DESCRIPTION πŸ¦‹

ngl, this tool is just a front end for the DBI::ProxyServer package. that's it. all it does is pick options off the command line and call DBI::ProxyServer::main(). that's the entire job, and honestly? respect. πŸ’…

if you want the real details, go see DBI::ProxyServer β€” it's got the lore.

available options include (get comfy, there's a bunch):

  • --chroot=dir β€” (UNIX only 🐧) after doing a bind(), it changes the root directory to the given directory by doing a chroot(). it's giving security, and it's iconic for that, but it also restricts the environment a lot. like, for example, you need to load DBI drivers in the config file, or you have to create hard links to Unix sockets if your drivers are using them. for example, with MySQL, a config file might contain the following lines:
my $rootdir = '/var/dbiproxy';
my $unixsockdir = '/tmp';
my $unixsockfile = 'mysql.sock';
foreach $dir ($rootdir, "$rootdir$unixsockdir") {
    mkdir 0755, $dir;
}
link("$unixsockdir/$unixsockfile",
     "$rootdir$unixsockdir/$unixsockfile");
require DBD::mysql;

{
    'chroot' => $rootdir,
    ...
}

if you don't know chroot(), think of an FTP server where you can only see a certain directory tree after logging in. also see the --group and --user options 🧚

  • --configfile=file β€” config files are assumed to return a single hash ref that overrides the arguments of the new method. however β€” plot twist β€” command line arguments in turn take precedence over the config file. so the command line is the main character here, periodt. see the "CONFIGURATION FILE" section in the DBI::ProxyServer documentation for the details on the config file πŸ’–
  • --debug β€” turns debugging mode on. mainly this asserts that logging messages of level "debug" are created. it's giving investigative journalist πŸ”
  • --facility=mode β€” (UNIX only 🐧) facility to use for Sys::Syslog. the default is daemon.
  • --group=gid β€” after doing a bind(), change the real and effective GID to the given one. useful if you want your server to bind to a privileged port (<1024) but don't want the server to execute as root. see also the --user option 🫢

GID's can be passed as group names or numeric values. both are valid, no gatekeeping.

  • --localaddr=ip β€” by default a daemon is listening to any IP number that a machine has. this attribute allows one to restrict the server to the given IP number. picky listener, we love to see it ✨
  • --localport=port β€” this attribute sets the port on which the daemon is listening. it must be given somehow, as there's no default. so like, don't forget it. seriously. no default. none. 😭
  • --logfile=file β€” by default logging messages will be written to the syslog (Unix) or to the event log (Windows NT). on other operating systems you need to specify a log file. the special value "STDERR" forces logging to stderr. see Net::Daemon::Log for details πŸ“
  • --mode=modename β€” the server can run in three different modes, depending on the environment. ok so:
    • if you are running Perl 5.005 and did compile it for threads, then the server will create a new thread for each connection. the thread will execute the server's Run() method and then terminate. this mode is the default, you can force it with --mode=threads 🧡
    • if threads are not available, but you have a working fork(), then the server will behave similar by creating a new process for each connection. this mode will be used automatically in the absence of threads, or if you use the --mode=fork option.
    • finally there's a single-connection mode: if the server has accepted a connection, he will enter the Run() method. no other connections are accepted until the Run() method returns (if the client disconnects). this operation mode is useful if you have neither threads nor fork(), for example on the Macintosh. for debugging purposes you can force this mode with --mode=single 🍎
  • --pidfile=file β€” (UNIX only 🐧) if this option is present, a PID file will be created at the given location. default is to not create a pidfile. lowkey humble of it.
  • --user=uid β€” after doing a bind(), change the real and effective UID to the given one. this is useful if you want your server to bind to a privileged port (<1024) but don't want the server to execute as root. see also the --group and the --chroot options πŸ‘‘

UID's can be passed as group names or numeric values. (yes, group names β€” that's what the page says, and we're keeping it exactly as written, bestie πŸ’œ)

  • --version β€” suppresses startup of the server; instead the version string will be printed and the program exits immediately. hit it and quit it πŸ’¨

πŸŽ€ AUTHOR πŸŽ€

Copyright (c) 1997 Jochen Wiedmann Am Eisteich 9 72555 Metzingen Germany

Email: joe@ispsoft.de Phone: +49 7123 14881

the DBI::ProxyServer module is free software; you can redistribute it and/or modify it under the same terms as Perl itself. in particular, permission is granted to Tim Bunce for distributing this as a part of the DBI 🌈


πŸ’€ SEE ALSO πŸ’€

DBI::ProxyServer, DBD::Proxy, DBI β€” go read those next, iykyk πŸ“š


and that's the whole page, bestie!! this was perl v5.42.2, dated 2026-07-25, and it's DBIPROXY(1) β€” no cap, you now know the entire thing. go proxy something iconic πŸ’–βœ¨πŸŽ€πŸ¦‹

πŸ“¦ where this page comes from