Archive

Archive for the ‘Linux’ Category

Fedora LVM to Ubuntu ext3

August 3rd, 2011 No comments
Categories: Linux Tags: ,

DDWRT speed limit

July 7th, 2011 No comments

Save Script as Administrator -> Commands -> Save Firewall

CODE:
  1. # Firewall Script Start<br />
  2.     # Wait 10 seconds for Router startup<br />
  3.     sleep 10<br />
  4.     # br2 Web Access Only<br />
  5.     iptables -I FORWARD -i br2 -m state --state NEW -j ACCEPT<br />
  6.     iptables -I FORWARD -p tcp --tcp-flags SYN,RST SYN -j TCPMSS --clamp-mss-to-pmtu<br />
  7.     iptables -I FORWARD -i br2 -d `nvram get lan_ipaddr`/`nvram get lan_netmask` -m state --state NEW -j DROP<br />
  8.     iptables -t nat -I POSTROUTING -o br0 -j SNAT --to `nvram get lan_ipaddr`<br />
  9.     iptables -I INPUT -i br2 -m state --state NEW -j DROP<br />
  10.     iptables -I INPUT -i br2 -p udp --dport 67 -j ACCEPT<br />
  11.     iptables -I INPUT -i br2 -p udp --dport 53 -j ACCEPT<br />
  12.     iptables -I INPUT -i br2 -p tcp --dport 53 -j ACCEPT<br />
  13.     # Share Printer with br2<br />
  14.     iptables -I FORWARD -d 192.168.1.30 -j ACCEPT<br />
  15.     # Limit br2 download speed<br />
  16.     tc qdisc del dev br2 root<br />
  17.     tc qdisc add dev br2 root handle 1: htb<br />
  18.     tc class add dev br2 parent 1:1 classid 1:10 htb rate 1024kbit ceil 1024kbit prio 4<br />
  19.     tc filter add dev br2 parent 1:0 prio 4 protocol ip handle 10 fw flowid 1:10<br />
  20.     iptables -t mangle -A POSTROUTING -d 192.168.10.0/24 -j MARK --set-mark 10<br />
  21.     # Limit br2 upload speed<br />
  22.     insmod imq<br />
  23.     insmod ipt_IMQ<br />
  24.     ip link set imq0 up<br />
  25.     tc qdisc del dev imq0 root<br />
  26.     tc qdisc add dev imq0 root handle 1: htb<br />
  27.     tc class add dev imq0 parent 1:1 classid 1:10 htb rate 100kbit ceil 100kbit prio 4<br />
  28.     tc filter add dev imq0 parent 1:0 prio 4 protocol ip handle 10 fw flowid 1:10<br />
  29.     iptables -t mangle -A PREROUTING -s 192.168.10.0/24 -j MARK --set-mark 10<br />
  30.     iptables -t mangle -A PREROUTING -j IMQ --todev 0<br />
  31.     # Firewall Script Ends

Change br2 with your brX, also change 192.168.10.0/24 to your needs

Note about “prio”, I’ve set it the lowest=4. Prio values are 0-4; 0=Highest, 1=High, 2=Normal, 3=Low & 4=Lowest

Categories: Linux, Malo mešano Tags: ,

9 – How to make a USB bootable BACKTRACK 4/5 (linux) drive – RMPrepUSB

June 17th, 2011 No comments

title BackTrack 5 (1024x768) Persistent\nType startx to run GUI once booted PERSISTENT

kernel /casper/vmlinuz file=/cdrom/preseed/custom.seed boot=casper text splash vga=791-- persistent

initrd /casper/initrd.gz

via 9 - How to make a USB bootable BACKTRACK 4/5 (linux) drive - RMPrepUSB.

Categories: Linux Tags:

Installing MySQL And phpMyAdmin On FreeNAS | HowtoForge – Linux Howtos and Tutorials

May 30th, 2011 No comments

Installing MySQL And phpMyAdmin On FreeNAS | HowtoForge - Linux Howtos and Tutorials.

!!!!!

mysql_install_db --user=mysql --ldata=/new-data-location

Categories: Linux Tags:

Linux connecto to VPN

December 30th, 2010 No comments

pppd noauth refuse-eap require-mppe name umbit password umbitgeslo usepeerdns require-chapms-v2 pty "pptp mail.nektar.eu --nolaunchpppd"

http://www.question-defense.com/2009/08/13/configure-wrt54gs-running-dd-wrt-to-connect-to-office-vpn-connection

http://open-wrt.ru/forum/viewtopic.php?pid=2108

Type of VPN: PPTP
CHAP
MS-CHAP v2
 

10.0.1.1        0.0.0.0         255.255.255.255 UH    0      0        0 ppp0
193.189.184.134 192.168.2.1     255.255.255.255 UGH   0      0        0 eth0

pppd  noauth  nobsdcomp  nodeflate  require-mppe-128  name  umbit password umbitgeslo  pty "pptp mail.nektar.eu --nolaunchpppd"

Categories: Linux Tags:

nano Command Manual

November 24th, 2010 No comments

5 Nanorc Files

set undo
set historylog
set tabsize 4
set const

via nano Command Manual.

Categories: Linux Tags:

FreeNAS forum • View topic – mount other NAS share using SMBFS

October 14th, 2010 No comments

mount_smbfs //toto@NAS-BACKUP/Volume_1-1 /mnt/BACKUP_NAS/

via FreeNAS forum • View topic - mount other NAS share using SMBFS.

Categories: Linux Tags:

Winexe 0.91 for [FreeBSD 7.3 | FreeNAS 0.7.1]

October 6th, 2010 No comments

Winexe 0.91 for [FreeBSD 7.3 | FreeNAS 0.7.1]

Compiled on FreeBSD 7.3

Winexe-FreeBSD

Categories: Linux Tags:

Linux, bash find in files

September 30th, 2010 No comments

find . -type f -exec grep -i "redeem reward" {} \; -print 2>/dev/null

Categories: Bash, Linux Tags:

Multiple WLANs – DD-WRT Wiki

February 14th, 2010 No comments
Categories: Linux, Wireless Tags:

Setting up a Subversion Server on Ubuntu Gutsy Gibbon server | Subversionary

November 4th, 2009 No comments

Setting up a Subversion Server on Ubuntu Gutsy Gibbon server via Setting up a Subversion Server on Ubuntu Gutsy Gibbon server | Subversionary.

 

How to perfect setup server

http://how2forge.org/perfect-server-ubuntu-9.10-karmic-koala-ispconfig-2-p6

Categories: Linux Tags:

Install Subversion with Web Access on Ubuntu :: the How-To Geek

November 3rd, 2009 No comments

Install Subversion with Web Access on Ubuntu This article covers installing subversion with the apache module so that it can be easily accessed from other systems on a public network. If you want a more secure svn server, you could use svnserve+ssh, which isn’t covered in this article. To install subversion, open a terminal and run the following command: via Install Subversion with Web Access on Ubuntu :: the How-To Geek.

 

How to perfect setup server

http://how2forge.org/perfect-server-ubuntu-9.10-karmic-koala-ispconfig-2-p6

Categories: Linux Tags:

Find IP

August 14th, 2009 No comments

Find IP

You get onto a network and can't, or don't want, to use DHCP, how to you find out what IP addresses are available? Find IP is a bash script inspired by a an app called marco which performs the same task but is written in python and requires a number of libraries, Find IPs only dependency is arping.

Download Find IP.

See the README file for usage notes.

via Find IP - DigiNinja.

Categories: Linux Tags:
17039 pages viewed, 0 today
11071 visits, 0 today
FireStats icon Powered by FireStats