Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
The Merkinman
Apr 22, 2007

I sell only quality merkins. What is a merkin you ask? Why, it's a wig for your genitals!
This is more of a general hardware question, but Ubuntu 9.04 is my main OS.

My Kingston Traveler 16GB drives keeps randomly unmounting. Now it doesn't seem to mount at all and lsusb says it's a CompUSA 128 Pen Drive.

Adbot
ADBOT LOVES YOU

Hughmoris
Apr 21, 2007
Let's go to the abyss!
A family member has an infected computer running Windows XP. I need to back up her pictures and then flatten it to install Windows 7 or Ubuntu 9.04. If I have my choice, it will be Ubuntu for the very reason that she always gets viruses.

Anywho, I'm worried about plugging my external USB drive to her computer and get that infected as well. I read somewhere that I can pop in a Ubuntu 9.04 CD, run a LIVE session and backup the files that way. Will I be able to access pictures that are on a windows partition and move them to an external usb drive if I'm running a LIVE session?

The Merkinman
Apr 22, 2007

I sell only quality merkins. What is a merkin you ask? Why, it's a wig for your genitals!

Hughmoris posted:

A family member has an infected computer running Windows XP. I need to back up her pictures and then flatten it to install Windows 7 or Ubuntu 9.04. If I have my choice, it will be Ubuntu for the very reason that she always gets viruses.

Anywho, I'm worried about plugging my external USB drive to her computer and get that infected as well. I read somewhere that I can pop in a Ubuntu 9.04 CD, run a LIVE session and backup the files that way. Will I be able to access pictures that are on a windows partition and move them to an external usb drive if I'm running a LIVE session?

Simply put, yes, as I've done this.


Also I managed to reformat my 16GB drive on a work computer.

Hughmoris
Apr 21, 2007
Let's go to the abyss!

The Merkinman posted:

Simply put, yes, as I've done this.


Also I managed to reformat my 16GB drive on a work computer.

I just did a trial run on my computer, and it recognized my Windows XP partition just fine. Also mounted my external usb drive automatically. Great stuff.

Beve Stuscemi
Jun 6, 2001




I am running an SFTP server on Ubuntu that accepts files into a directory via SFTP, then a cronjob runs every minute that copies them out to a mounted directory on another server.

Here is my setup:

All files received via SFTP are dumped in /home/SFTPDrop I have a shared directory on a windows server mounted to /mnt/dbsrv. Inside the SFTPDrop folder are various uploaded files, including some directories


Here is my fstab that mounts the directory:
code:
//10.0.0.8/incoming /mnt/dbsrv   cifs   credentials=/etc/.smbcredentials,iocharset=utf8,file_mode=0777,dir_mode=0777 0 0
/etc/.smbcredentials contains the following:
code:
username=username@domain
password=password
Mount reports the following:
code:
 //10.0.0.8/incoming on /mnt/dbsrv type cifs (rw,mand)
My Crontab contains this:
code:
*/2* *** root /mnt/copySFTP.sh
The file /mnt/copySFTP contains the following:
code:
#!/bin/sh

cp -r /home/SFTPDrop /mnt/dbsrv
This fails giving me the following error:

quote:

cp: cannot create symbolic link '/mnt/dbsrv/Files': Operation not supported

Anyone have any idea why this fails? Whats wrong here?

Crush
Jan 18, 2004
jot bought me this account, I now have to suck him off.
What's the best way to allow ONLY a certain range of host masks access to a box running linux (actually a NAS) so that there is never even a prompt for username/password for anything (SSH, FTP, SFTP, Web (browser) Management, etc.) unless a computer within a certain host mask is trying to access it?

Bob Morales
Aug 18, 2006


Just wear the fucking mask, Bob

I don't care how many people I probably infected with COVID-19 while refusing to wear a mask, my comfort is far more important than the health and safety of everyone around me!

Crush posted:

What's the best way to allow ONLY a certain range of host masks access to a box running linux (actually a NAS) so that there is never even a prompt for username/password for anything (SSH, FTP, SFTP, Web (browser) Management, etc.) unless a computer within a certain host mask is trying to access it?

Can you edit the hosts allow/deny in the smb.conf?

also, which firewall is it using? for example, in iptables you can do something like:
# iptables -A INPUT -p tcp -s 192.168.0.0/16 --dport 80 -i ppp0 -j ACCEPT

to allow web traffic from 192.168.x.x

Crush
Jan 18, 2004
jot bought me this account, I now have to suck him off.

Bob Morales posted:

Can you edit the hosts allow/deny in the smb.conf?

also, which firewall is it using? for example, in iptables you can do something like:
# iptables -A INPUT -p tcp -s 192.168.0.0/16 --dport 80 -i ppp0 -j ACCEPT

to allow web traffic from 192.168.x.x

the smb.conf file it has does not seem to have options like that. iptables does not seem to exist on this NAS.

I forgot to mention that I am wanting to remotely access this from outside the network while keeping it as locked down as possible (that's why I want to limit it to a host mask). Something like *.city.isp.com.

cLin
Apr 21, 2003
lat3nt.net
I figure I'd ask here since this is in regards to my server running freebsd...Is there something I can use that'll generate screencaps or even just a screenshot for every media file in a certain folder on my server?

The files are completely legal, we lost some files when one of our techs deleted a directory by mistake and now I want to find certain video files without having to download each one and viewing it myself. I figure I can just download all the screencaps and find what I need there.

Bob Morales
Aug 18, 2006


Just wear the fucking mask, Bob

I don't care how many people I probably infected with COVID-19 while refusing to wear a mask, my comfort is far more important than the health and safety of everyone around me!

cLin posted:

I figure I'd ask here since this is in regards to my server running freebsd...Is there something I can use that'll generate screencaps or even just a screenshot for every media file in a certain folder on my server?

The files are completely legal, we lost some files when one of our techs deleted a directory by mistake and now I want to find certain video files without having to download each one and viewing it myself. I figure I can just download all the screencaps and find what I need there.

Browse them with a Windows PC and look at the thumbnails generated?

cLin
Apr 21, 2003
lat3nt.net

Bob Morales posted:

Browse them with a Windows PC and look at the thumbnails generated?

That doesn't seem to generate any thumbnails. I did however try it on my computer with random media files and it does generate it although some file formats don't (ends up showing the VLC icon).

Maybe the files need to be on a windows pc?

2.7182818284590
Dec 10, 2004

lol custom title more like custom DICKS

cLin posted:

That doesn't seem to generate any thumbnails. I did however try it on my computer with random media files and it does generate it although some file formats don't (ends up showing the VLC icon).

Maybe the files need to be on a windows pc?

Use a Ubuntu LiveCD and set the preview preferences in a nautilus window through Edit->Preferences->Preview.

That or you can use totem-video-thumbnailer.

KICK BAMA KICK
Mar 2, 2009

On Ubuntu 9.04, I want to prepend the same string to the names of all files in a directory. (e.g., rename files "001.txt", "002.txt", "003.txt" to "abc-001.txt", "abc-002.txt" and "abc-003.txt" in one fell swoop). Is there a terminal command I could plausibly remember to do this?

Tad Naff
Jul 8, 2004

I told you you'd be sorry buying an emoticon, but no, you were hung over. Well look at you now. It's not catching on at all!
:backtowork:

A Violence Gang posted:

On Ubuntu 9.04, I want to prepend the same string to the names of all files in a directory. (e.g., rename files "001.txt", "002.txt", "003.txt" to "abc-001.txt", "abc-002.txt" and "abc-003.txt" in one fell swoop). Is there a terminal command I could plausibly remember to do this?

rename?

KICK BAMA KICK
Mar 2, 2009

FeloniousDrunk posted:

rename?

Oh awesome, the quick bash intros I'd read didn't bother to mention that, only mv. How would I format the command to add, for example, "abc-" to the beginning of every filename in the current directory? I'm not fluent with regexes or whatever it uses.

Tad Naff
Jul 8, 2004

I told you you'd be sorry buying an emoticon, but no, you were hung over. Well look at you now. It's not catching on at all!
:backtowork:

A Violence Gang posted:

Oh awesome, the quick bash intros I'd read didn't bother to mention that, only mv. How would I format the command to add, for example, "abc-" to the beginning of every filename in the current directory? I'm not fluent with regexes or whatever it uses.

I don't think rename is part of bash, I think it's part of the "util-linux" package, in Ubuntu anyway.

To do what you describe,
code:
rename 's/^/abc-/' *

KICK BAMA KICK
Mar 2, 2009

FeloniousDrunk posted:

I don't think rename is part of bash, I think it's part of the "util-linux" package, in Ubuntu anyway.

To do what you describe,
code:
rename 's/^/abc-/' *

Appreciated. Now I just have to invent a mnemonic for that.

e: or yeah I should just throw that in a script

grumm3t
Jul 1, 2004
k

Crush posted:

the smb.conf file it has does not seem to have options like that. iptables does not seem to exist on this NAS.

I forgot to mention that I am wanting to remotely access this from outside the network while keeping it as locked down as possible (that's why I want to limit it to a host mask). Something like *.city.isp.com.

I'm not sure if you can block the resolved hostname via smb.conf, but the ISP probably has a block of IPs it puts clients on. You can probably take the first two octets and be relatively safe.

Ex. if you IP is 74.54.16.138 add

code:
hosts deny = ALL
hosts allow = 74.54. 127.0.0.1
Under your share. Without the loopback, some errors can be generated.

e: quoted wrong post

grumm3t fucked around with this message at 12:39 on Jun 18, 2009

grumm3t
Jul 1, 2004
k

Phat_Albert posted:

Anyone have any idea why this fails? Whats wrong here?

The Files folder in /home/SFTPDrop is a symbolic link to somewhere. You can either remove the symbolic link (if possible) or tell cp to follow symbolic links with a -L flag.

e: clarity

grumm3t
Jul 1, 2004
k

cLin posted:

That doesn't seem to generate any thumbnails. I did however try it on my computer with random media files and it does generate it although some file formats don't (ends up showing the VLC icon).

Maybe the files need to be on a windows pc?

This isn't really helpful but on some :filez: sites there is a collection of thumbnails pulled from throughout the movie. If you can find the program for linux you could setup a bash script to grab each avi and pass it to the program, then downloaded the resultant thumbnails. Let me see if I can find said program.

e: Well ffmpeg and imagemagick can apparently do the trick if you have either installed.

ffmpeg: http://blog.prashanthellina.com/2008/03/29/creating-video-thumbnails-using-ffmpeg/
imagemagick: http://www.imagemagick.org/script/convert.php (try just `convert movie.avi screenshot.jpg` to start)

grumm3t fucked around with this message at 12:57 on Jun 18, 2009

deong
Jun 13, 2001

I'll see you in heck!

A Violence Gang posted:

Appreciated. Now I just have to invent a mnemonic for that.

e: or yeah I should just throw that in a script

If you like visual, you can also use the Bulk Renamer for Thunar, although its a fairly bloated package for just a renamer.. you have to d/l the full thunar package. Works great though :D

Crush
Jan 18, 2004
jot bought me this account, I now have to suck him off.

grumm3t posted:

I'm not sure if you can block the resolved hostname via smb.conf, but the ISP probably has a block of IPs it puts clients on. You can probably take the first two octets and be relatively safe.

Ex. if you IP is 74.54.16.138 add

code:
hosts deny = ALL
hosts allow = 74.54. 127.0.0.1
Under your share. Without the loopback, some errors can be generated.

e: quoted wrong post

Will modifying the smb.conf (that doesn't seem to have option for deny/allow) block access for EVERYTHING (SSH, FTP, SFTP, and Web Management (xxxx.dyndns.org:80)) or will it just deny access for file sharing itself?

bitprophet
Jul 22, 2004
Taco Defender

Crush posted:

Will modifying the smb.conf (that doesn't seem to have option for deny/allow) block access for EVERYTHING (SSH, FTP, SFTP, and Web Management (xxxx.dyndns.org:80)) or will it just deny access for file sharing itself?

Don't read this in a mean tone of voice, but why would you think that modifying the SMB specific conf file, would prevent access to anything else on the system besides SMB? Serious question :D

Crush
Jan 18, 2004
jot bought me this account, I now have to suck him off.

bitprophet posted:

Don't read this in a mean tone of voice, but why would you think that modifying the SMB specific conf file, would prevent access to anything else on the system besides SMB? Serious question :D

Yeah, that was what I was getting at. I didn't understand why everyone would want me to modify the smb config file for something that broad.

bitprophet
Jul 22, 2004
Taco Defender

Crush posted:

Yeah, that was what I was getting at. I didn't understand why everyone would want me to modify the smb config file for something that broad.

Sorry, I'd been skimming the related posts up till now. Rereading, you definitely want /etc/hosts.(allow|deny), but that's not necessarily available on all systems, and I'm not at all sure it will work with DNS names like *.domain.tld -- it may well only work with IP addresses / networks. But it's the most widespread, general "block all network traffic for X / allow only network traffic from Y" mechanism I'm aware of, alongside firewalls like iptables / ipchains (god that's old now isn't it) / pf.

I'm sure there are solutions out there that can firewall in the way you want, though, I just don't know off the top of my head, and if you're using some sort of embedded/stripped-down Unix on a NAS, your options may be limited unless you're willing to roll up your sleeves and compile stuff from sources.

Do you know if the NAS is running a specific flavor/distro of Unix? That may help us find more info. If there's no docs telling you and the motd on login doesn't say anything, try looking for /etc/redhat-release, /etc/lsb-release, /etc/debian_version or similar files. Those would exist if it derives from RedHat or Debian based systems, at any rate.

Crush
Jan 18, 2004
jot bought me this account, I now have to suck him off.

bitprophet posted:

Sorry, I'd been skimming the related posts up till now. Rereading, you definitely want /etc/hosts.(allow|deny), but that's not necessarily available on all systems, and I'm not at all sure it will work with DNS names like *.domain.tld -- it may well only work with IP addresses / networks. But it's the most widespread, general "block all network traffic for X / allow only network traffic from Y" mechanism I'm aware of, alongside firewalls like iptables / ipchains (god that's old now isn't it) / pf.

I'm sure there are solutions out there that can firewall in the way you want, though, I just don't know off the top of my head, and if you're using some sort of embedded/stripped-down Unix on a NAS, your options may be limited unless you're willing to roll up your sleeves and compile stuff from sources.

Do you know if the NAS is running a specific flavor/distro of Unix? That may help us find more info. If there's no docs telling you and the motd on login doesn't say anything, try looking for /etc/redhat-release, /etc/lsb-release, /etc/debian_version or similar files. Those would exist if it derives from RedHat or Debian based systems, at any rate.

This is the best I can do :(

quote:

Linux [hostname] 2.6.12.6-arm1 #31 Thu Mar 26 18:20:41 CST 2009 armv5tejl GNU/Linux

bitprophet
Jul 22, 2004
Taco Defender

Crush posted:

This is the best I can do :(

The "GNU/Linux" implies it might be Debian related, though I'd be surprised if Debian was the _only_ distro that refers to itself as GNU/Linux. No /etc/debian_version file floating around? What about an "apt-get" binary?

At this point I'm not sure we can help much without actually sitting at a shell on this thing, so if you've looked for "ipchains" or "iptables" or "pf" and not finding any binaries with those names -- and there's no /etc/hosts.allow type files in /etc -- you may be SOL. (Do you have an external firewall, or could get one? That would be another way around this...)

Accipiter
Jan 24, 2004

SINATRA.

bitprophet posted:

The "GNU/Linux" implies it might be Debian related

No.

bitprophet
Jul 22, 2004
Taco Defender

Accipiter posted:

No.

Oh, don't be facile, they ARE well known for harping about being "Debian GNU/Linux" and get pissy when you call it just "Debian Linux". You're right, though, that uname will print GNU/Linux on at least some other distros, so my assumption based on just uname was incorrect v:shobon:v

Since you're clearly more on top of things than I am, why don't you try helping Crush out? Or are you only here to correct people ;)

Accipiter
Jan 24, 2004

SINATRA.

bitprophet posted:

You're right, though, that uname will print GNU/Linux on at least some other distros, so my assumption based on just uname was incorrect v:shobon:v

The information is pulled from the kernel, not the distribution.

In any case, whatever system it's running, it's an ARM port.

bitprophet
Jul 22, 2004
Taco Defender

Accipiter posted:

The information is pulled from the kernel, not the distribution.

In any case, whatever system it's running, it's an ARM port.

Yea, I saw that. Not sure it tells us a lot, though; Debian has supported ARM directly for a long time, but there also seem to be RedHat-like distros for the architecture, and it could easily be something less well-known, or totally custom.

Is there anything else he should look for besides hosts.(allow|deny), ip(chains|tables) or pf?

(Speaking of hosts.allow/deny, I looked at a random manpage for it and at least on RedHat and Debian distros, it does support DNS lookups, so my earlier assumption that it works on IP/network addresses only was thankfully incorrect.)

covener
Jan 10, 2004

You know, for kids!

Accipiter posted:

The information is pulled from the kernel, not the distribution.

Not the GNU/Linux part, that's baked into the GNU uname binary when it's built.

Accipiter
Jan 24, 2004

SINATRA.

covener posted:

Not the GNU/Linux part, that's baked into the GNU uname binary when it's built.

I'm referring to the fact that it's not asking the distribution what kernel is running, but that it's talking to the kernel directly.

Crush
Jan 18, 2004
jot bought me this account, I now have to suck him off.

bitprophet posted:

The "GNU/Linux" implies it might be Debian related, though I'd be surprised if Debian was the _only_ distro that refers to itself as GNU/Linux. No /etc/debian_version file floating around? What about an "apt-get" binary?

At this point I'm not sure we can help much without actually sitting at a shell on this thing, so if you've looked for "ipchains" or "iptables" or "pf" and not finding any binaries with those names -- and there's no /etc/hosts.allow type files in /etc -- you may be SOL. (Do you have an external firewall, or could get one? That would be another way around this...)

I have router, but that's about it. Is there any other way to just make this stupidly secure? I still want to be able to run Transmission on it without blocking access to that as well.

maskenfreiheit
Dec 30, 2004
Edit: Double Post

maskenfreiheit fucked around with this message at 20:54 on Mar 13, 2017

maskenfreiheit
Dec 30, 2004
Edit: Double Post

maskenfreiheit fucked around with this message at 20:50 on Mar 13, 2017

ShoulderDaemon
Oct 9, 2003
support goon fund
Taco Defender
git clone, not git-clone. The variants with hyphens were deprecated a few versions ago.

maskenfreiheit
Dec 30, 2004
Edit: Double Post

maskenfreiheit fucked around with this message at 20:54 on Mar 13, 2017

HappyGrifter
Jul 25, 2003
I have a Centos 5 box and I want to export my display to my TV. My Video card and my PC both support HDMI, however my current on-board sound card is not supported in Centos 5 and it doesn't have a SPDIF connector.

I'm looking at new sound cards - something cheap and with an SPDIF pass through. Does anyone know if Linux compatability/drivers are required for the pass through to work? Or will I require a card with Centos support? I really just want sound through my TV.

Adbot
ADBOT LOVES YOU

tripwire
Nov 19, 2004

        ghost flow
I'm trying to get a Canon MP600 series printer installed in Ubuntu and it is far more painful than it should be.

The process other people are following is to take a canon red hat package and convert it to a debian package with the alien utility.

Alien fails to convert this package because it cannot find any libraries.
These libraries should be available at /usr/lib so I have no idea why the gently caress it wouldn't look there but anyway, the error message it prints out is:
code:
To help dpkg-shlibdeps find private libraries, you might need to set LD_LIBRARY_PATH.
dpkg-shlibdeps: failure: couldn't find library libtiff.so.3 needed by debian/cnijfilter-mp600/usr/local/bin/cifmp600 (its RPATH is '').
Note: libraries are not searched in other binary packages that do not have any shlibs or symbols file.
To help dpkg-shlibdeps find private libraries, you might need to set LD_LIBRARY_PATH.
dh_shlibdeps: dpkg-shlibdeps returned exit code 2
I can edit the makefile it is using, but I don't know the makefile syntax for setting an environment variable.

I assume something like "export LD_LIBRARY_PATH = $LD_LIBRARY_PATH:/usr/lib" would do the trick.. how do you put that into a makefile?

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply