Showing posts with label UNIX. Show all posts
Showing posts with label UNIX. Show all posts

Wednesday 6 March 2024

Create a Django Project On Mac or Linux

1. install python3 - download from python website 
2. install vertual env : 
sudo pip install virtualenv 
3. create a project directory : 
mkdir djproject 
4. create a virtual environment cd djproject virtualenv myvirtenv -p python3 
5. activate the virtual environment : source myvirtenv/bin/activate
 
6. install Django inside the virtual environment
 pip install Django (installs the latest version) 
7. start the project, creates the project files 
django-admin startproject djproject
8. start the webserver 
python manage.py runserver
 
9. Launch the webpage on thedefault port 
http://127.0.0.1:8000 
you should see django up an running!

Wednesday 25 August 2010

cannot restore segment prot after reloc: Permission denied

Error on CentOS 5 while starting a proccess

cannot restore segment prot after reloc: Permission denied

Noticed while running networker 7.6 on Centos 5

Resolution:

Centos has SELinux enabled by default and set to 'enforcing'

temporarily disable by running: /usr/sbin/setenforce 0

you can change SELinux config at /etc/selinux/config

Tuesday 15 June 2010

DIsable firewall on SuSE 11

The firewall is enabled by default , to stop it

/etc/init.d/SuSEfirewall2_setup stop

Unable to SSH to SuSE 11

Check if sshd is running , if not start it up

/etc.init.d/sshd status
/etc.init.d/sshd start

The firewall is enabled by default , you may have to stop/reconfigure it

/etc/init.d/SuSEfirewall2_setup stop

Thursday 29 April 2010

Ubuntu 10

Ok its officially out 10.04 :)


Ignore the below issue they have fixed it

<<<<<<<<<<<<<<<<<<

Dont upgarde just yet if you are on dual boot :
https://bugs.launchpad.net/ubuntu/+source/ubiquity/+bug/570765



Ubuntu: For Desktops, Servers, Netbooks and in the cloud

Wednesday 21 April 2010

do_ypcall: clnt_call: RPC: Unable to receive; errno = Connection refused

Getting errors like:

do_ypcall: clnt_call: RPC: Unable to receive; errno = Connection refused

alos causes any public key ssh setup with no password authenticaton to fail

Resolution:
check if ypbind is running (/etc/init.d/ypbind status) and restart it (/etc/init.d/ypbind start)

Cause:
Check if it is set to run when the box reboots?
Also if it loses connection to the nis master, it may not reconnect.

Tuesday 13 April 2010

Find files with string in current directory

Find files with string in current directory:

find . -follow -name "*" -exec grep -i eng.wysdm.com {} \; -print

Linux - file size limit exceeded

run ulimit -a to check your current limit

eg.,

file size (blocks, -f) 2048


means it is limited to 2 MB

this can be changed in /etc/security/limits.conf to be set to unlimited

Friday 9 April 2010

top on solaris , free memory on solaris, memory usage on solaris

To find out the free memory available on solaris

vmstat - free virtual memory status

prstat - current process memory usage status

else install top

AIX uninstall problems

Ok your are on AIX and get the wierd problem of not able to uninstall this app installed using install shield

Remove the entry from vpd.properties , but where is vpd.properties
..hmm here /usr/lib/objrepos, remove entries from there and you are good to go

Tuesday 22 December 2009

Ubuntu

Ubuntu is cool, if you are using windows and never tried a different operating system before, then this is just the right time.

If you are scared of having to put a new operating system on your PC, well, don't be. The nice guys have made it as simple as installing a new software.

Try it and you will thank me.

wubi-installer.org

Word Press Multisite on AWS instance cannot login with default password

  Word Press Multisite on AWS instance cannot login with default password after setting a static IP ? Try this Login to the shell from AWS i...