Wednesday, November 28, 2012

My struggle with setting up slackware 14 vsftp using a mounted windows share for the home directory

I'm in the process of taking our virtual slackware server and making a physical server running the newest slackware 14.  Along the way i've hit a few issue with newer vsftpd.

I originally hit a 500 error on login because it was not allowing login to users with write access to home.
2nd issue I had was my fstab mount using cifs to a windows machine.  Users could login and download files but they could not upload any files. 530 error message would display.

Below are my steps on a fresh clean install of slackware 14.  It will cover commands that I used to setup mirrors, configure vsftpd.config, inetd.conf, adding a new user, adding a share to fstab and running openssl for the sftp part.

information that needs to be entered in will be in the color red everything else is just my comments or instructions.

After you get to terminal we need to uncomment a location to use slackpkg update.
From terminal type:  vim /etc/slackpkg/mirrors
Exit vim by saving with :wq

Now we need to run from terminal slackpkg update
vim /etc/vsftpd.conf

From what is listed I have uncommented this below.
I had to add in Allow_writeable_chroot=YES to get past the 500 error


anonymous_enable=no
local_enable=YES
write_enable=YES
local_umask=000
ftpd_banner=Private FTP.
chroot_local_user=YES
chroot_list_enable=YES
allow_writeable_chroot=YES
chroot_list_file=/etc/vsftpd.chroot_list

I commented out
#local_umask=022

Save by :wq

vim /etc/inetd.conf
We need to remove the comments from the line below Very Secure Transfer Protocol(FTP) server.
ftp stream tcp nowait root /usr/sbin/tcpd vsftpd
to save :wq

restart the service from terminal by entering
/etc/rc.d/rc.inetd restart

Any users that you want to have full access to all folder on the ftp and not be locked down to their home needs to be placed in the chroot list based on what we have in our changes to vsftpd.conf
vim /etc/vsftpd.chroot_list

Create a directory under home to mount the windows share later
mkdir /home/ftp

Adding our windows share to fstab is my next step.  I had to add in for options gid=ftp,dir_mode=0777 to allow the users to upload files to the share.  If not it would display the 530 error.
vim /etc/fstab

//servername/foldershare  /home/ftp  cifs  gid=ftp,dir_mode=0777,rw,directio,username=windowusername,password=password 0 0
:wq

Now its time to create our users. I prefer to use terminal adduser and follow through the command prompts entering what information is needed.
When it asks for home it will give a default /home/username  change it to be /home/ftp/userid
the user home is now on the windows share
When it asks for groups add the user to group = ftp

Setting up SSl from terminal i chose to run this with 365 days with an rsa key of 1024

openssl req -x509 -nodes -days 365 -newkey rsa:1024 -keyout /etc/vsftpd/vsftpd.pem -out /etc/vsftpd/vsftpd.pem

Now we need to edit the inetd.conf to enable ssl Below are the values i added or changed
vim /etc/inetd.conf
ssl_enable=YES
allow_anon_ssl=NO
force_local_data_ssl=NO
force_local_logins_ssl=NO
ssl_tlsv1=YES
ssl_sslv2=NO
ssl_sslv3=NO
rsa_cert_file=/etc/vsftpd/vsftpd.pem
:wq


Making any changes to this file you will need to either restart the system or issue the kill hup command.
I find it easiest to just restart the server before testing out ftp.


That is all the steps that I took to set up a slackware 14 vsftp server with sftp using a mounted windows share for the home directory.

I did have to ask for help in a forum to figure out my issue with fstab windows mount not allowing file uploads.  Through those suggestions I was able to apply the dir_mode option.

I hope this helps anyone else that ran into the same issue as I did.

Monday, September 24, 2012

edimensional AudioFx headset - Adjusting the volume so your ears dont bleed

I've had one hell of a time with this headset.  Master volume for the system would be almost as low as it would go and I felt like i was going to loose my hearing.

It was either on and ear bleeding or off.

Finally on my 3rd time through downloading and installing the software i noticed under its own software was a settign to adjust output device.


Their software under control panel is called USB PnP Sound Device.

Launch this and on the main setting tab will have different sectioned off panes.  Look at the Output Device.
Click the Sound icon volume.  it will then display a slider for left/right.  For me the sweet spot was -30db on both.

Doing this puts the headset back at a normal volume that wont lead you to shouting at your co-workers from lack of hearing.

Hope this helps.

Thursday, March 22, 2012

How to tell what port a program needs open

This is an issue I run into.  Searching forums for threads that tell you what ports need to be open to let an application work properly.

Most of the time you can find these on their wiki or on the software's forums.  Sometimes the port is listed but its outdated information.

Here is a fairly quick and easy method to find out some information.

Tools needed, application running that is giving the issue, windows command prompt and  task manager.

Open Task manager and click on the processes tab.  The bottom right is a check box to show process from all users. Go ahead and check that.    Under the menue click view->select columns.

Check PID and press ok.

From the application you need to find the port for launch it and log into the server if possible.
Switch to command prompt and type in    netstat -ano

Look at task manager for the running application and write down the PID number.

For example a game  launcher.exe  has a pid of 8081.

looking at netstat for pid 8081 i see it is pointing to an external IP address and its using port 10781.

Bingo thats the port number i need to open.


Hope this helps people out.  If you are trying to open up ports for a game this may get you in the door, most games have ranges of ports that are a few hundred ports.  Way to many to open up for in my case.

If you can open up all ports for a given ip go that route. its a lot easier.

Friday, February 17, 2012

Ubuntu how to run a minecraft snapshot

It has been a while since i've had to update a snap shot and being on the linux side i couldn't remember where a lot of it was.

First go to minecraft.net download minecraft.jar

choose properties and check executable.

Run the file and it will create the rest of the files by downloading them from mojang.

browse from your home folder to .minecraft. There will be a folder now bin
Open that and now take your snapshot minecraft.jar and overwrite it.

I also checked allow executing.


After that finished go to the original minecraft.jar and run with java. log in and you will see the update version there.

Monday, January 30, 2012

Oracle Public Synonms troubles

I got schooled today on this topic.

Our internal users were having issues trying to restore database through our front end web interface.
They were able to pick the database server but the drop down for all the schemas were blank.

Quickly getting to the point  the public synonym for sys.dba_users was missing.

Easy way to see this is from enterprise manager drill down to Schema > Public>  there should be an object called DBA_USERS.

To fix our issue loggin in as Sys

CREATE PUBLIC SYNONYM DBA_USERS FOR DBA_USERS;
COMMIT;


After that was ran all of the schemas populate the drop down list now.

Hope this will help people.

BSOD on newly imaged dell

Had a strange issue when i tried to image a laptop it went through it's normal process and imaged the machine.

When it started to boot into windows it displayed the normal startup window then went straight to blue screen.  Pulling the hard drive and viewing windows\minidump showed that nothing was written to the hard drive.

I got to thinking hmm maybe it is a bad hard drive.  Running diag scan I did not find any issues.

Last step enter the Bios and see what there is to be seen.

The sata drive was set to AHCI. switching this to raid ready and poof computer boots without issue into windows.



Wednesday, January 18, 2012

Win 7 Sp1 failed to install because of old version of Security Essentials

Oh yeah SP1 u cant install because Security Essentials is installed Ha ha ha... Wait windows updates doesnt show any updates for security essentials and it doesnt appear to be running under process NO WAY....

yeah it was a Houdini issues.   Luckily I stumbled on a MS article telling that the anti virus program can cause the sp1 to fail on update.

Sure enough only place to see it was there was under add/remove programs.

Got rid of it and now sp1 is installing.

Thursday, January 12, 2012

Not able to ping computers on the same switch simple fix

This is one of those issues that just perplexes you for a while until you go OH silly me this is how you fix it.

I'm trying to get 5 laptops ready for a demo that will be using IIS and a Database server.
So currently i'm at the stage where all laptops are powered on and connected to a 8 port switch.

From command prompt i'm typing in the trusted ipconfig. Look at all the results and find it a bit odd all ips are class B for an 8 port switch.

Each machine doesnt even have the same first 3 bits its just all over the place for ips.

From command prompt i start to ping the machine to the right but i'm not getting back any reply. I'm thinking its an icmp so why isnt it going through..

Thought strucks me must be windows firewall.

Sure enough i go to inbound rules and look under file and print ICMP echo is not enabled.
Once i enabled on all the laptops firewalls they all started pinging and replying i'm here now use us.

Short post but none the less helpfull.

Thursday, January 5, 2012

Data migration for existing user to a new pc

This is something that i've been struggling with for a few years now at my current position.

Setting up a new machine for an existing user with data.
There are solutions out there such as windows easy transfer but I find this just doesn't help me much.

I would say most users here do not know how to run this even with a guide or say it takes to much time to do. Really dont buy that answer so I gave up on doing that.

So far the only solution i found is to use the Admin share to transfer their data through our network.

This isnt so bad but it takes time to find out where all there data is scattered.
For some reason people jsut dont want to use my documents or desktop they want to have 100s of folders under c drive.

We have even setup a file share where each user gets 30gb of storage but hardly anyone uses that either.


For those who havent used the admin share here is a brief example.

Old computer where the data resides is called comp1 and i'm currently logged into the new machine as administrator.

\\comp1\c$ Thats it. It will prompt you for the user\pass so enter it in for that machine administrator.

From here on its 2 windows open with copy paste to move the data.
I could setup some scripts for the known folders but really with all the data scattered its easier for em to use the CTRL click method.


Wednesday, January 4, 2012

process that I took to upgrade my droidx to ICS

There are many search results now that pull back info on ICS for droidx. Or variants but not the full thing.

I had previously rooted my droidx and installed a early gingerbread rom so i was way back on the version.

Almost all of the information I used was from rootzwiki.com.

First step that I needed to do was get my phone to the latest gb build. At the time of writing this it was 605.

The sbf files that i used only got up to 602.

Great Guide is here.


After installing and logging into the phone i performed an OTA to get to 605.

Once that rebooted i ran the one click Root.

I initially had issues getting clockwork recovery to work. Previously i had the free version of droid2 boot strap from the devs personal website i believe. That is no longer available for dowload there. The old apk i had installed but wasnt working for reboots.

Was only stock recover. So i bite the bullet and bought it from the Market for $3

After that rom manger was working and it rebooted into clockwork recovery.


The rom i'm using now is the Encounter ICS beta 3. Rootzwiki has a great write up on it with file and gapp to flash as well.

Rebooting into clockwork recovery I previously did not wipe the cach or factor wipe it. This was really needed.

Install from here takes about 4 mins maybe.

Phone starts up with a new interesting loading screen and will take about 30 seconds to load. If it keeps going on and on for a few mins more than likely you didnt wipe it and the cache. Follow the guide and be sure to get the 3 things they list.

Phone will start up with the new log in screen. Then the fun Verizon activation if you have that carrier.

Currently in beta 3 there are only a few minor things to me that are not working.
Camera. I think if this gets the drivers for this phone worked out this will be the perfect rom to use. I can wait it out : ) so far its stable and perfect.

For Netflix dont grab the apk from the market. When a movie plays the sound is perfect but the video is a black screen. Search the thread for netflix and it has some info for netflix to get it working. It is working now for me.

last issue is usb storage when you plug the phone into a computer. It shows the drive but will not let you open the drive. On the apps menue look for USB Mass Storage. run that and all will be good.

Over all i like it a lot over Gingerbread. Each release by google always improves in my own opinion. Its a shame moto isnt having an offical ICS for the droidx that I know of. It can handle it from my usage and would be great for others to have.

Since the phone i have is still under that lovely 2 year contract i'm sure its to get people to upgrade and not waste their time in making it work.

If you want to test this out go for it but you do it at your own risk.

Just in case most droid x phones on craigslist were running 80 to 160. just in case you mess it up so bad you have to get a replacement.

non booting Opti 990

This was a fairly good one that had me today.

Machine when powering on would spin up the fans and hard drive but would not show any output to the lcd screen.

I had a like opti 990 model so i removed the video card and swaped them since i've seen video cards go out.

That wasnt the issue. Next step remove the memory and boot it up at 2 sticks at a time.
That was it memory issues. So i went through each pair to find out non of the memory was bad. Just needed to be reset and everything booted properly.

Bios mem test showed nothing wrong as well.

So when in doubt always reset devices and cables just to be sure in shipping something didnt jiggle free. BUT i swear the mem chips were all pushed in properly and snug.