Skip to main content

Questions tagged [bsd]

The BSD (Berkeley Software Distribution) is a UNIX operating system developed by University of California at Berkeley during the 70s and 80s.

Filter by
Sorted by
Tagged with
0 votes
1 answer
2k views

How To SetUP SOCKS5 Proxy Server on Linux based OS

What is the best way to setup SOCKS5 proxy server on *nix? I have tried a lot of solutions but really not impressed For instance one GO-based solution just not working, another option is to use ssh ...
Грибной Щер's user avatar
0 votes
1 answer
150 views

Mount remote directory of server with no direct route but having an intermediate server that only receives ssh connections

The setup I'm facing is this one: In server A I'd like to mount a directory (let's call it SHARED) from server B. There is no route and no way to add any from A to B or from B to A. The inverse, to ...
Luis's user avatar
  • 730
16 votes
4 answers
9k views

What's the simplest way to display a browser-based interface on a computer without a GUI?

I am converting an old laptop into what will basically just be a terminal for some of my other computers. For the most part, I only need to ssh into my computers, and that I can do with any CLI-based ...
Valiant's user avatar
  • 191
1 vote
1 answer
690 views

Can you underline directories in zsh with ls?

I would like to underline directories when I do ls. Is this possible in a default Mac terminal and zsh? Or do I need something like iTerm2 + ohmyzsh. From what I found LSCOLORS doesn't support ...
Bn.F76's user avatar
  • 134
1 vote
0 answers
321 views

Moving the mouse cursor (not just screen) in vim

With my .vimrc under Linux I can scroll using my mouse wheel and the cursor itself goes up and down, shifting the lines shown on the screen if necessary. Using the same .vimrc and vim installed from ...
Ken - Enough about Monica's user avatar
0 votes
1 answer
2k views

vi command line editing insert mode overwrite

I'm using Windows Terminal (TERM=xterm-256color) in a bash shell under Ubuntu: uname -a Linux xxxxxxx 4.19.128-microsoft-standard #1 SMP Tue Jun 23 12:58:10 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux I'...
Dweeberly's user avatar
  • 111
2 votes
0 answers
1k views

What is the explanation of the network flags in MacOSX? [closed]

Good morning. Could someone explain to me the meaning of the flags in the routing table? For example if you check the output of netstat -nr you will have lines like this: default 192.168.2....
n3mo's user avatar
  • 133
1 vote
1 answer
54 views

Besides BSD and Linux, are there any other open-source Unix descendants currently in development? [closed]

This week I'm going to install every major BSD and Linux distro and learn for myself how they differ. Are there any other Unix open-source projects besides these two ancestors that I should consider ...
Freeman's user avatar
  • 155
0 votes
1 answer
384 views

I accidentally ran `rm -rf /` what should I do

I accidentally ran rm -rf / on my macos machine, most files were protected since I was not running the command as root, but I definitely lost some files in /usr/local, are there any other files I ...
Alexander Mills's user avatar
0 votes
2 answers
228 views

Installing a second OS carries a risk of data loss; even your PC's user manual says so. If you have backups, is it now okay to install a second OS?

Background A variety of Samsung laptops say something like this in their user manuals (PDF): If you change the product's factory OS (Operating System) to another OS, or if you install software which ...
unforgettableidSupportsMonica's user avatar
0 votes
0 answers
117 views

INACCESSIBLE BOOT DEVICE BSOD on Windows 10

I am getting the error INACCESSIBLE BOOT DEVICE, I have tried everything.the computer is in an infinite loop of restarting. Safe mode doesn't start, the reset this PC doesn't work, the uninstall ...
Tito's user avatar
  • 151
0 votes
3 answers
4k views

how can I get the yes command to force overwrite and to do so with new lines?

I would like cp to prompt before overwriting so I am using -i. (I might sometimes use an alias for cp, or similar, so cp always occurs with -i). I may want to say overwrite all. I know that's the ...
barlop's user avatar
  • 24.5k
1 vote
2 answers
364 views

Delete emails from specific source in mailx/BSD mail

I need to delete all emails from a specific source. I can list all of the emails with the f [email protected] but I'm having to dump it to something like awk and back into mail... or copy all of ...
MrSchism's user avatar
4 votes
2 answers
15k views

How could a hacker access the /etc/shadow file if it is only accessible by root and they do not have root access?

I am reading a book on ethical hacking, and it has some examples in Python which I won't post here unless asked since this isn't Stack Overflow. But, I was wondering, if a hacker was trying to access ...
Andy Meza III's user avatar
1 vote
1 answer
341 views

Can I share my home among multiple operating systems?

Is it possible to have on the same hard disk a single home partition (e.g. EXT4), shared by multiple operating systems? What I would like to do is to install Linux, HURD and DragonFlyBSD on the same ...
Pietro's user avatar
  • 1,791
0 votes
0 answers
527 views

conversion from GNU sed to BSD sed

I am new to sed and am trying to implement this answer on a mac. After some quick research I believe I have to convert the code to BSD sed. I haven't had much success looking into the BSD sed ...
karlahrnndz's user avatar
5 votes
5 answers
3k views

How to chain awk print statements?

Okay, here's a quick example; me isolating a host's IPV4 in three steps: ip -br a lo UNKNOWN 127.0.0.1/8 ::1/128 eth0 DOWN wlan0 UP ...
voices's user avatar
  • 2,801
2 votes
1 answer
7k views

pkg install using specific version of Python in FreeBSD?

How do you 'pkg install' a package using specific version of Python in FreeBSD 11? say I want to 'pkg install' using Python 3?
user727967's user avatar
0 votes
1 answer
74 views

Why does blocksize arguments change for shell utilities on Linux vs OSX?

When following a tutorial for flashing a ROM that uses the dd utility, I received an console warning that '1M' was not a supported blocksize. OSX requires a blocksize of '1m'. What is the root ...
haysclark's user avatar
  • 121
0 votes
0 answers
220 views

What version of tar does 7-zip use?

Does anyone know what version of tar 7zip uses for archiving/extracting? Is it gnu tar or bsd tar... or something else? I've googled around for an answer but can't find anything.
olfek's user avatar
  • 247
5 votes
4 answers
7k views

Is there a native alternative to the `watch` command; for Darwin/OS X

I have a script that I'm trying to port from Linux to Darwin/OS X. The Linux version currently depends on the watch command, which doesn't appear to be installed on Darwin/OS X by default. What's the ...
voices's user avatar
  • 2,801
1 vote
0 answers
265 views

bsd (osx) pf nat - change source port on outgoing UDP packets

I am running docker-machine on osx. docker-machine is running NAT so when my container send out a UDP packet on port 1812, NAT is translating it to some random port. I am playing around with pf nat (...
roocell's user avatar
  • 111
0 votes
1 answer
736 views

Using specific grep flags from BSD general commands version on a Mac

So I have been using a command piped through curl (on GNU/Linux's grep utility) to generate a random password string for tightening security on some of my accounts. curl -s https://www.grc.com/...
shome_slice's user avatar
2 votes
1 answer
2k views

Why is Bash reporting “command not found” in some cases in the Terminal but not in others?

Often, but not always, when I start the Terminal on my computer and use pipe (|) in a command, pbpaste | wc as an example, bash gives -bash:  wc: command not found. (The double space is not a typo). ...
xenia's user avatar
  • 147
1 vote
1 answer
2k views

Alternate location for GPT partition entry table

The GPT header (usually in LBA 1) has a PartitionEntryLBA field (see 5.3.2 GPT Header in the spec). There is language in various references (such as the wikipedia GPT entry) describing that field ...
Juan's user avatar
  • 619
1 vote
0 answers
1k views

Netstat VS Netstat (Gnu/Linux VS BSD/Mac OS X)

Why are there different versions of netstat for Gnu/Linux and BSD/Mac OS X? I'm trying to get the latter to respond & behave more like the former.
voices's user avatar
  • 2,801
17 votes
2 answers
36k views

Recursively compress files in a directory and subdirectories using command line "zip" tool in Mac OS X and exclude .DS_Store files from ALL subfolders

I'm trying to create a ZIP file using the command line zip tool that comes with the Mac OS X Terminal. I want to recursively compress the contents of the current folder but excluding .DS_Store files. ...
OMA's user avatar
  • 1,740
1 vote
2 answers
43 views

Compare list of files from a database using find to locate missing files

I have a list of 2000 files from a database that looks like this: ./aa/0f/unique-string/IMG_0987.JPG ./ab/cf/unique-string/IMG_0987.JPG I want to compare that list to the actual directory contents ...
jakethedog's user avatar
161 votes
3 answers
8k views

On OS X, why does `sudo ls` show hidden (dot) files?

With OS X Yosemite, using the following commands, I get the following: $ touch .a $ touch b $ /bin/ls b $ /bin/ls -A .a b $ sudo /bin/ls .a b It shows hidden files (that have names starting with a ...
kirelagin's user avatar
  • 2,882
4 votes
1 answer
7k views

Why can't I use my newly created user with chown?

So I am attempting to create a new user and group, and then change ownership of a directory to that new user/group. However, when I do, chown comes back with an "illegal user name" message. Here's a ...
Wilco's user avatar
  • 661
1 vote
1 answer
399 views

How can I make this SED command more portable?

I'm using the following sed command: cat version | sed -e 's/[0-9][0-9][0-9][0-9][0-9:M]*-[abp]/Ver\n/' Which normalizes like this: 4330M-p -> Ver<newline> This works fine with GNU SED, ...
WilliamKF's user avatar
  • 7,968
8 votes
1 answer
743 views

Forcing *BSD to accept both IPv4 and IPv6 traffic on a single socket

I have tried a ton of stuff and keep coming up entirely empty handed. Allow me to frame the situation: I have a *BSD Jail setup in FreeNAS that runs a Plex Media Server (Plexpass). It has IPv6 ...
Nathanial Meek's user avatar
1 vote
0 answers
44 views

BSD Packet Filter Redirect Internal traffic

I'm using OSX Yosemite with Packet Filter (BSD). Is there a way to redirect internal originating traffic (let's say from en1) to lo0 on a specific port for specific destinations? rdr from what I ...
ktln2003's user avatar
2 votes
1 answer
2k views

PF rule using return-rst on Mac OS X does not reply with TCP reset

I'm trying to add a simple PF rule: block return-rst out proto tcp from any to any port 33128 to filter all outgoing traffic to TCP port 33128, and I'd like it to respond with a reset. However, when ...
ldx's user avatar
  • 121
8 votes
2 answers
3k views

Interactive search of tmux sessions

When switching between tmux sessions with the interactive session menu (<prefix>-s), you can jump to a specific session by typing the session's numeric or alphabetical index, e.g. (0) + ...
GerritS's user avatar
  • 183
2 votes
2 answers
117 views

How does an OS run before drivers are installed?

I am looking into hardware compatibility of BSD vs Linux vs Windows. One comment that keeps reoccurring is "check your hardware before installing any variant of BSD". This is also a (smaller) issue ...
Ephemera's user avatar
  • 1,381
0 votes
1 answer
480 views

PC shutdown unexpectedly without blue screen

My PC is shutting down after few hours(?) without BSD, but keyboard lights, power LED, fans are running (it's not sleep mood or hibernating). To switch them off I have to switch off the UPS, holding ...
Confused User's user avatar
3 votes
1 answer
3k views

Port forwarding outgoing request with PF

I'm trying to redirect all outgoing traffic from my local machine on port 843, to go to my local service on port 1234. So, when I make a request to e.g. 1.2.3.4:843, I want it to connect to 127.0.0.1:...
Alexander Olsson's user avatar
0 votes
3 answers
159 views

What is a better approach for ZFS?

I am making zpools on FreeBSD machine. While creating zpools I observe these two cases:- If I take raw disks and create zpool then I am able to form zpools and they are working perfectly. If I format ...
shivams's user avatar
  • 121
0 votes
0 answers
270 views

Can user-mode Linux be compiled and run on UNIX systems?

e.g. on NetBSD or Solaris? Or does it require exclusively Linux-specific system calls, virtual filesystems, etc.? Also, if it's currently limited to Linux, what changes would be required to port it ...
DanL4096's user avatar
  • 171
0 votes
2 answers
266 views

Is there any Linux Distro based on BSD

I have hp probook 4530s. I have tried variety of OS on this but after using 10-15mins its screen flicks and the system hangs. Check the attached screenshot This screen flicks for all windows OSs, ...
coure2011's user avatar
  • 1,639
2 votes
4 answers
16k views

trying to install FreeBSD from a pen drive. Failed with error 19

I am trying to install FreeBSD from a pen drive. But it returns an error on boot. cd9660 :/dev/iso9660 error :/dev/iso9660/FREEBSD_INSTALL failed with error 19 and appears mountroot> command ? ...
user628298's user avatar
8 votes
1 answer
3k views

What's are the technical differences between "chmod -w file" and "chflags uchg file"

BSD/MacOS question. chmod -w file will remove all the write permissions from file chflags uchg file will set the user-immutable bit (aka "Locked" bit) on file Beyond the obvious statement of "...
selbie's user avatar
  • 303
11 votes
2 answers
5k views

How do you determine if you're on a Linux or BSD system inside a script?

I've got a rather extensive selection of dotfiles thats been kept in a git repo for the longest time - I just maintain a separate branch of code for bsd-isms (for instance, on Linux, to get colored ls ...
Karu's user avatar
  • 4,802
29 votes
2 answers
35k views

Why do we use cp to copy files and not dd? (in unix-derivatives)

For normal file copying in *nix, I've only ever seen people use cp (eg. cp /mnt/mydevice/myfile ~/myfile), but I eventually ran into dd, which appears to do the exact same thing (dd if=/mnt/mydevice/...
user232105's user avatar
7 votes
1 answer
1k views

FreeBSD compatibility layer on Linux

I am aware of Linux mode on FreeBSD, where Linux binaries can seamlessly be executed in FreeBSD. From the FreeBSD handbook: In effect, there is a Linux kernel in the FreeBSD kernel. The various ...
William Breathitt Gray's user avatar
0 votes
1 answer
2k views

Backup bootable USB flash in Mac OS X

I have a bootable USB. It runs Linux. The size of USB pen is 8Gb, and linux partitions take less than 200Mb. $ diskutil list /dev/disk0 #: TYPE NAME SIZE ...
Anthony Ananich's user avatar
19 votes
3 answers
19k views

What is the BSD equivalent of Linux `netstat -lptun`?

In Linux, netstat -lptun gives a list of servers with the following details: protocol local and foreign address state PID and program name What is the command's equivalent in FreeBSD? Thanks.
Howard's user avatar
  • 2,306
23 votes
3 answers
2k views

Sudo su vs su linux

If I enter in the password to su when prompted, it doesnt work while sudo su does. Also, when a command is executed using sudo (command), does sudo automatically execute it by root by default (since ...
agz's user avatar
  • 8,358
0 votes
1 answer
240 views

Install linux/bsd on compact flash using USB connector

How do I install linux/bsd on compact flash with usb compact flash adapter. The compact flash will boot on single board x86 computer as an IDE drive, but I'm doing the install on a regular computer ...
user avatar