Showing posts with label linux. Show all posts
Showing posts with label linux. Show all posts

Redhat configuration (RHEL3, RHEL4, RHEL5)

Redhat configuration : pbraun.nethence.com/doc/sysutils_linux/redhat.html
Daily mail reports with logwatch : pbraun.nethence.com/doc/sysutils/logwatch.html
Log rotation techniques : pbraun.nethence.com/doc/sysutils/log_rotation.html
Redhat/XEN configuration : pbraun.nethence.com/doc/sysutils/xen_redhat.html

Introduction
For RHEL3, RHEL4, RHEL5. We recomment to install a minimal Redhat (only @base) and proceed with other using YUM against a DVD or the network.

Redhat sources : ftp.redhat.com/
CentOS mirrors : mirror-status.centos.org/

Post-install configuration in brief
- disable security level and selinux
- environment
- network configuration
- services
- syslog
- lvm
- additional packages
- sync time
- mail alias
- screen
- file indexation
(-) rhn


Post-install configuration
Disable security level and selinux
On Redhat's first boot,
Security level : disabled
SELinux : disabled
Note. otherwise once system has booted,
system-config-securitylevel-tui

Environment
Remove motd and show hidden files,
cd /etc
cat motd
#mv motd motd.dist
vi bashrc
add,
PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:$HOME/bin
LANG=C
export PATH LANG

[[ $USER = root ]] && \
PS1='${HOSTNAME%%.*}# ' \
PS1='${HOSTNAME%%.*}> '

case "$-" in *i*)
alias rm='rm -i'
alias cp='cp -i'
alias mv='mv -i'
alias ll='ls -alkF'
alias vi='vim'

who
;;
esac
apply immediately,
source bashrc

No freacking colors,
cd ~/
echo "syn off" >> .vimrc
cat ~/.vimrc

Remove skeletons but bashrc and bash_profile,
cd /etc
mv skel skel.dist
mkdir skel
cp skel.dist/.bashrc skel
cp skel.dist/.bash_profile skel
cp ~/.vimrc skel

Setup default group,
useradd -D -g users
Note. also tweakable in /etc/default/useradd

Network configuration
Configure hostname and gateway,
vi /etc/sysconfig/network
like,
NETWORKING=yes
NETWORKING_IPV6=no
HOSTNAME=host.example.net
GATEWAY=10.1.1.254

Configure IP and netmask,
vi /etc/sysconfig/network-scripts/ifcfg-eth0
like,
DEVICE=eth0
BOOTPROTO=static
IPADDR=10.1.1.1
NETMASK=255.255.255.0
ONBOOT=yes
Note. "BOOTPROTO=static" is checked during Oracle installation
Note. remove HWADDR so you can replace network cards transparently (works best since RHEL5 and maybe on latest RHEL4s, bugs were fixed)
Note. otherwise,
#system-network-config-tui

Apply,
hostname host.example.net
service network restart

Configure file based host name resolution,
vi /etc/hosts
like,
127.0.0.1 localhost.localdomain localhost
#rhel5: ::1 localhost6.localdomain6 localhost6
10.1.1.254 gw.example.net gw
10.1.1.1 host.example.net host

Fix name resolution,
vi /etc/resolv.conf
like,
search example.net
nameserver DNS1_IP
nameserver DNS2_IP


Services
On RHEL3,
service apmd stop
service autofs stop
service cups stop
chkconfig apmd off
chkconfig autofs off
chkconfig cups off

On RHEL4,
service apmd stop
service autofs stop
service cups stop
service acpid stop
service bluetooth stop
service haldaemon stop
service hidd stop
service pcmcia stop

chkconfig apmd off
chkconfig autofs off
chkconfig cups off
chkconfig acpid off
chkconfig bluetooth off
chkconfig haldaemon off
chkconfig hidd off
chkconfig pcmcia off

On RHEL5,
#service acpid stop
service atd stop
service auditd stop
service autofs stop
service avahi-daemon stop
service bluetooth stop
service cups stop
service firstboot stop
#service haldaemon stop
service hidd stop
service pcscd stop
service yum-updatesd stop

#chkconfig acpid off
chkconfig atd off
chkconfig auditd off
chkconfig autofs off
chkconfig avahi-daemon off
chkconfig bluetooth off
chkconfig cups off
chkconfig firstboot off
#chkconfig haldaemon off
chkconfig hidd off
chkconfig pcscd off
chkconfig yum-updatesd off

Note. if xen domU,
#chkconfig microcode_ctl off
Note. if Compaq Smart Array (cciss),
#chkconfig smartd off
Note. if using serial console only, no PC console
#chkconfig gpm off

Syslog
Send all the system logs in one single file,
cd /etc
mv syslog.conf syslog.conf.dist
vi syslog.conf
like,
*.* -/var/log/messages
apply,
service syslog restart

Fix perms,
chown root:wheel /var/log/messages
chmod 640 /var/log/messages

LVM
Exclude CDrom from LVM,
cd /etc/lvm
cp lvm.conf lvm.conf.dist
vi lvm.conf
change the filter directive to,
filter = [ "r/dev/cdrom" ]
Note. if you've got SAN you might aslo want to exclude sd* and let LVM handle only dm-0

Additional packages
Configure your YUM repository and make sure you've got those installed,
rpm -q \
sendmail \
man \
man-pages \
xorg-x11-xauth \
screen \
wget \
lynx \
lftp \
ntp \
vsftpd \
vim-enhanced \
cvs \
grep ^package
#rhel4 & rhel5 : mc
#rhel5 : mlocate
#rhel4 : slocate
#rhel3: XFree86-xauth
eventually,
#rpm-build
#rpm-devel
#gallery2-imagemagick or ImageMagick

Screen
Configure,
cd /etc
mv screenrc screenrc.dist
vi screenrc
like,
startup_message off
caption always "%-Lw%{= BW}%50>%n%f* %t%{-}%+Lw%< %{=b BW} %H %{-} %l %c %d/%m/%Y" bindkey ^[, prev bindkey ^[; next shelltitle "" autodetach on defscrollback 65000 then user specifics, cd ~/ vi .screenrc like, screen -t "log" 0 tail -F /var/log/messages and launch, cd ~/ screen Sync time cd /etc mv ntp.conf ntp.conf.dist #sed '/^#/d; /^$/d;' ntp.conf.dist > ntp.conf
vi ntp.conf
like,
restrict default kod nomodify notrap nopeer noquery
restrict -6 default kod nomodify notrap nopeer noquery
restrict 127.0.0.1
restrict -6 ::1
server ntp.obspm.fr
driftfile /var/lib/ntp/drift
keys /etc/ntp/keys
apply,
service ntpd start
chkconfig ntpd on

Otherwise,
#ntpdate -u ntp.obspm.fr
or even simply,
#date -s 20091020
#date -s 09:24

Mail alias
Configure the root and wheel users aliases,
cd /etc
vi aliases
change,
root: yourmail@example.net
check for MX and apply,
host -t mx example.net
newaliases

File indexation
Update the mlocate database,
updatedb

RHN
Register to the Redhat network,
rhn_register


Advanced configuration
FTP server
Enable vsftpd,
rpm -q vsftpd
service vsftpd start
chkconfig vsftpd on
Note. /etc/skel was configured previously

You can now create FTP users


Miscellaneous
Prevent ctrl-alt-suppr from restarting the box,
vi /etc/inittab
comment that line,
#ca::ctrlaltdel:/sbin/shutdown -t3 -r now

To change language's locale,
vi /etc/sysconfig/i18n

To get everything through serial console, configure GRUB and inittab.
Ref. www.faqs.org/docs/pocket_linux/x1252.html


Advanced network configuration
Check network interfaces negociation & link,
ethtool eth0 grep Link

To force network interface's bandwidth,
ethtool -s eth0 speed 1000 duplex full autoneg off
And apply it permanently,
vi /etc/sysconfig/network-scripts/ifcfg-eth0
for example,
ETHTOOL_OPTS="speed 1000 duplex full autoneg off"

As for static routes,
vi /etc/sysconfig/static-routes
or
vi /etc/sysconfig/network-scripts/route-ethX
e.g.,
GATEWAY0=10.10.0.1
NETMASK0=255.0.0.0
ADDRESS0=10.0.0.0

GATEWAY1=10.2.0.1
NETMASK1=255.255.0.0
ADDRESS1=192.168.0.0

Refs.
web.mit.edu/rhel-doc/5/RHEL-5-manual/Deployment_Guide-en-US/pt-network-related-config.html
kbase.redhat.com/faq/FAQ_79_2561.shtm


RHEL installation numbers
They're supposed to simplify deployments in environments with different subscriptions. However, it's just a pain for non supported Redhats. Here are a few working install numbers as a workaround,
Client,
0000000e0017fc01
Server,
000000e90007fc00
Server with Cluster,
00000065000bfc00
Server with ClusterStorage,
000000ab000ffc00
Server with HPC,
000000e30013fc00
Server with Directory,
000000890017fc00
Server with SMB,
00000052001bfc00
Ref. linuxczar.net/moin/RHEL_Instaltion_Numbers
Ref. www.redhat.com/support/resources/faqs/installation_numbers/


Huge memory
RHEL4 had the hugemem kernel but it wasn't recommended to use it even though you had 64Go+ of RAM. Today RHEL5 is fine with default kernel, althouth HP says it runs with max 64Go in its OS compatibility table.


Comparison & critics
- how to fix it afterwards if a fake/temporary install number has been given during installation ?
- the useless "complete log install.log" warning during install
- initrd shouldn't exist. At least the disk drivers should be included into the bare kernel.
- when updating httpd with "yum update", files that were intentionally removed come back, like,
/etc/httpd/conf.d/welcome.conf
Note. this may unfortunately happen with other updates.
- should be english only, no translations. for example, lynx keyboard interaction stays english while the messages are in french. Spooky.
- logwatch sucks compared to custom scripts
- logrotate sucks compared to newsyslog
- RHEL vs Centos: silly constrain about the CDs


References
www.redhat.com/docs/manuals/enterprise/
web.mit.edu/rhel-doc/5/RHEL-5-manual/Deployment_Guide-en-US/
mirror.centos.org/centos/4/os/i386/NOTES/RELEASE-NOTES-U5-fr.html
Init scripts lock files : www.redhat.com/magazine/008jun05/departments/tips_tricks/

connect.c - SSH Proxy Command

SSH Proxy Command -- connect.c

connect.c is the simple relaying command to make network connection via SOCKS and https proxy. It is mainly intended to be used as proxy command of OpenSSH. You can make SSH session beyond the firewall with this command,

Features of connect.c are:

  • Supports SOCKS (version 4/4a/5) and https CONNECT method.
  • Supports NO-AUTH and USERPASS authentication of SOCKS
  • You can input password from tty, ssh-askpass or environment variable.
  • Run on UNIX or Windows platform.
  • You can compile with various C compiler (cc, gcc, Visual C, Borland C. etc.)
  • Simple and general program independent from OpenSSH.
  • You can also relay local socket stream instead of standard I/O.

Download source code from: http://www.taiyo.co.jp/~gotoh/ssh/connect.c
For windows user, pre-compiled binary is also available: http://www.taiyo.co.jp/~gotoh/ssh/connect.exe (compiled with MSVC)

What is 'proxy command'

OpenSSH development team decides to stop supporting SOCKS and any other tunneling mechanism. It was aimed to separate complexity to support various mechanism of proxying from core code. And they recommends more flexible mechanism: ProxyCommand option instead.

Proxy command mechanism is delegation of network stream communication. If ProxyCommand options is specified, SSH invoke specified external command and talk with standard I/O of thid command. Invoked command undertakes network communication with relaying to/from standard input/output including iniitial communication or negotiation for proxying. Thus, ssh can split out proxying code into external command.

The connect.c program was made for this purpose.

How to Use

Get Source

Download source code from here.
If you are MS Windows user, you can get pre-compiled binary from here.

Compile and Install

In most environment, you can compile connect.c simply. On UNIX environment, you can use cc or gcc. On Windows environment, you can use Microsoft Visual C, Borland C or Cygwin gcc.

Compilercommand line to compile
UNIX cccc connect.c -o connect
UNIX gccgcc connect.c -o connect
Solarisgcc connect.c -o connect -lnsl -lsocket -lresolv
Microsoft Visual C/C++cl connect.c wsock32.lib advapi32.lib
Borland Cbcc32 connect.c wsock32.lib advapi32.lib
Cygwin gccgcc connect.c -o connect
Mac OS/Darwingcc connect.c -o connect -lresolv

To install connect command, simply copy compiled binary to directory in your PATH (ex. /usr/local/bin). Like this:

$ cp connect /usr/local/bin

Modify your ~/.ssh/config

Modify your ~/.ssh/config file to use connect command as proxy command. For the case of SOCKS server is running on firewall host socks.local.net with port 1080, you can add ProxyCommand option in ~/.ssh/config, like this:

Host remote.outside.net
ProxyCommand connect -S socks.local.net %h %p

%h and %p will be replaced on invoking proxy command with target hostname and port specified to SSH command.

If you hate writing many entries of remote hosts, following example may help you.

## Outside of the firewall, use connect command with SOCKS conenction.
Host *
ProxyCommand connect -S socks.local.net %h %p

## Inside of the firewall, use connect command with direct connection.
Host *.local.net
ProxyCommand connect %h %p

If you want to use http proxy, use -H option instead of -S option in examle above, like this:

## Outside of the firewall, with HTTP proxy
Host *
ProxyCommand connect -H proxy.local.net:8080 %h %p

## Inside of the firewall, direct
Host *.local.net
ProxyCommand connect %h %p

Use SSH

After editing your ~/.ssh/config file, you are ready to use ssh. You can execute ssh without any special options as if remote host is IP reachable host. Following is an example to execute hostname command on host remote.outside.net.

$ ssh remote.outside.net hostname
remote.outside.net
$

Have trouble?

If you have trouble, execute connect command from command line with -d option to see what is happened. Some debug message may appear and reports progress. This information may tell you what is wrong. In this example, error has occurred on authentication stage of SOCKS5 protocol.

$ connect -d -S socks.local.net unknown.remote.outside.net 110
DEBUG: relay_method = SOCKS (2)
DEBUG: relay_host=socks.local.net
DEBUG: relay_port=1080
DEBUG: relay_user=gotoh
DEBUG: socks_version=5
DEBUG: socks_resolve=REMOTE (2)
DEBUG: local_type=stdio
DEBUG: dest_host=unknown.remote.outside.net
DEBUG: dest_port=110
DEBUG: Program is $Revision: 1.20 $
DEBUG: connecting to xxx.xxx.xxx.xxx:1080
DEBUG: begin_socks_relay()
DEBUG: atomic_out() [4 bytes]
DEBUG: >>> 05 02 00 02
DEBUG: atomic_in() [2 bytes]
DEBUG: <<< 05 02
DEBUG: auth method: USERPASS
DEBUG: atomic_out() [some bytes]
DEBUG: >>> xx xx xx xx ...
DEBUG: atomic_in() [2 bytes]
DEBUG: <<< 01 01
ERROR: Authentication faield.
FATAL: failed to begin relaying via SOCKS.

More Detail

Command line usage is here:

usage:  connect [-dnhs45] [-R resolve] [-p local-port] [-w sec]
[-H [user@]proxy-server[:port]]
[-S [user@]socks-server[:port]]
host port

host and port is target hostname and port-number to connect.

-H option specify hostname and port number of http proxy server to relay. If port is omitted, 80 is used. You can specify this value by environment variable HTTP_PROXY and give -h option to use it.

-S option specify hostname and port number of SOCKS server to relay. Like -H option, port number can be omit and default is 1080. You can also specify this value pair by environment variable SOCKS5_SERVER and give -s option to use it.

-4 and -5 is for specifying SOCKS protocol version. It is valid only using with -s or -S. Default is -5 (protocol version 5)

-R is for specifying method to resolve hostname. 3 keywords (local, remote, both) or dot-notation IP address is allowed. Keyword both means; "Try local first, then remote". If dot-notation IP address is specified, use this host as nameserver (UNIX only). Default is remote for SOCKS5 or local for others. On SOCKS4 protocol, remote resolving method (remote and both) use protocol version 4a.

The -p option will forward a local TCP port instead of using the standard input and output.

The -w option specifys timeout seconds for making connection with TARGET host.

The -a option specifiys user intended authentication methods separated by comma. Currently userpass and none are supported. Default is userpass. You can also specifying this parameter by the environment variable SOCKS5_AUTH.

The -d option is used for debug. If you fail to connect, use this and check request to and response from server.

You can omit port argument when program name is special format containing port number itself. For example,

$ ln -s connect connect-25
$ ./connect-25 smtphost.outside.net
220 smtphost.outside.net ESMTP Sendmail
QUIT
221 2.0.0 smtphost.remote.net closing connection
$

This example means that the command name "connect-25" contains port number 25 so you can omit 2nd argument (and used if specified explicitly).

Specifying user name via environment variables

There are 5 environemnt variables to specify user name without command line option. This mechanism is usefull for the user who using another user name different from system account.

SOCKS5_USER
Used for SOCKS v5 access.
SOCKS4_USER
Used for SOCKS v4 access.
SOCKS_USER
Used for SOCKS v5 or v4 access and varaibles above are not defined.
HTTP_PROXY_USER
Used for HTTP proxy access.
CONNECT_USER
Used for all type of access if all above are not defined.

Following table describes how user name is determined. Left most number is order to check. If variable is not defined, check next variable, and so on.


SOCKS v5SOCKS v4HTTP proxy
1SOCKS5_USERSOCKS4_USERHTTP_PROXY_USER
2SOCKS_USER
3CONNECT_USER
4(query user name to system)

Specifying password via environment variables

There are 5 environemnt variables to specify password. If you use this feature, please note that it is not secure way.

SOCKS5_PASSWD
Used for SOCKS v5 access. This variables is compatible with NEC SOCKS implementation.
SOCKS5_PASSWORD
Used for SOCKS v5 access if SOCKS5_PASSWD is not defined.
SOCKS_PASSWORD
Used for SOCKS v5 (or v4) access all above is not defined.
HTTP_PROXY_PASSWORD
Used for HTTP proxy access.
CONNECT_PASSWORD
Used for all type of access if all above are not defined.

Following table describes how password is determined. Left most number is order to check. If variable is not defined, check next variable, and so on. Finally ask to user interactively using external program or tty input.


SOCKS v5HTTP proxy
1SOCKS5_PASSWDHTTP_PROXY_PASSWORD
2SOCKS_PASSWORD
3CONNECT_PASSWORD
4(ask to user interactively)

Limitations

SOCKS5 authentication

Only NO-AUTH and USER/PASSWORD authentications are supported. GSSAPI authentication (RFC 1961) and other draft authentications (CHAP, EAP, MAF, etc.) is not supported.

HTTP authentication

BASIC authentication is supported but DIGEST authentication is not.

Switching proxy server

There is no mechanism to switch proxy server regarding to PC environment. This limitation might be bad news for mobile user. Since I do not want to make this program complex, I do not want to support although this feature is already requested. Please advice me if there is good idea of detecting environment to swich and simple way to specify conditioned directive of servers.

One tricky workaround exists. It is replacing ~/.ssh/config file by script on ppp up/down.

There's another example of wrapper script (contributed by Darren Tucker). This script costs executing ifconfig and grep to detect current environment, but it works. (NOTE: you should modify addresses if you use it.)

#!/bin/sh
## ~/bin/myconnect --- Proxy server switching wrapper

if ifconfig eth0 |grep "inet addr:192\.168\.1" >/dev/null; then
opts="-S 192.168.1.1:1080"
elif ifconfig eth0 |grep "inet addr:10\." >/dev/null; then
opts="-H 10.1.1.1:80"
else
opts="-s"
fi
exec /usr/local/bin/connect $opts $@

Tips

Proxying socket connection

In usual, connect.c relays network connection to/from standard input/output. By specifying -p option, however, connect.c relays local network stream instead of standard input/output. With this option, connect command waits connection from other program, then start relaying between both network stream.

This feature may be useful for the program which is hard to SOCKSify.

Use with ssh-askpass command

connect.c ask you password when authentication is required. If you are using on tty/pty terminal, connect can input from terminal with prompt. But you can also use ssh-askpass program to input password. If you are graphical environment like X Window or MS Windows, and program does not have tty/pty, and environment variable SSH_ASKPASS is specified, then connect.c invoke command specified by environment variable SSH_ASKPASS to input password. ssh-askpass program might be installed if you are using OpenSSH on UNIX environment. On Windows environment, pre-compiled binary is available from here.

This feature is limited on window system environment.

And also useful on Emacs on MS Windows (NT Emacs or Meadow). It is hard to send passphrase to connect command (and also ssh) because external command is invoked on hidden terminal and do I/O with this terminal. Using ssh-askpass avoids this problem.

Use for Network Stream of Emacs

Although connect.c is made for OpenSSH, it is generic and independent from OpenSSH. So we can use this for other purpose. For example, you can use this command in Emacs to open network connection with remote host over the firewall via SOCKS or HTTP proxy without SOCKSifying Emacs itself.

There is sample code: http://www.taiyo.co.jp/~gotoh/lisp/relay.el

With this code, you can use relay-open-network-stream function instead of open-network-stream to make network connection. See top comments of source for more detail.

Remote resolver

If you are SOCKS4 user on UNIX environment, you might want specify nameserver to resolve remote hostname. You can do it specifying -R option followed by IP address of resolver.

Hopping Connection via SSH

Conbination of ssh and connect command have more interesting usage. Following command makes indirect connection to host2:port from your current host via host1.

ssh host1 connect host2 port

This method is useful for the situations like:

  • You are outside of organizasion now, but you want to access an internal host barriered by firewall.
  • You want to use some service which is allowed only from some limited hosts.

For example, I want to use local NetNews service in my office from home. I cannot make NNTP session directly because NNTP host is barriered by firewall. Fortunately, I have ssh account on internal host and allowed using SOCKS5 on firewall from outside. So I use following command to connect to NNTP service.

$ ssh host1 connect news 119
200 news.my-office.com InterNetNews NNRP server INN 2.3.2 ready (posting ok).
quit
205 .
$

By combinating hopping connection and relay.el, I can read NetNews using Wanderlust on Emacs at home.

                        |
External (internet) | Internal (office)
|
+------+ +----------+ +-------+ +-----------+
| HOME | | firewall | | host1 | | NNTP host |
+------+ +----------+ +-------+ +-----------+
emacs <-------------- ssh ---------------> sshd <-- connect --> nntpd
<-- connect --> socksd <-- SOCKS -->

As an advanced example, you can use SSH hopping as fetchmail's plug-in program to access via secure tunnel. This method requires that connect program is insatalled on remote host. There's example of .fetchmailrc bellow. When fetchmail access to mail-server, you will login to remote host using SSH then execute connect program on remote host to relay conversation with pop server. Thus fetchmail can retrieve mails in secure.

poll mail-server protocol pop3 plugin "ssh %h connect localhost %p" username "username" password "password"

Break The More Restricted Wall

If firewall does not provide SOCKS nor HTTPS other than port 443, you cannot break the wall in usual way. But if you have you own host which is accessible from internet, you can make ssh connection to your own host by configuring sshd as waiting at port 443 instead of standard 22. By this, you can login to your own host via port 443. Once you have logged-in to extenal home machine, you can execute connect as second hop to make connection from your own host to final target host, like this:

$ cat ~/.ssh/config Host home ProxyCommand connect -H firewall:8080 %h 443

Host server ProxyCommand ssh home connect %h %p ... internal$ ssh home You are logged in to home! home# exit internal$ ssh server You are logged in to server! server# exit internal$

This way is similar to "Hopping connection via SSH" except configuring outer sshd as waiting at port 443 (https). This means that you have a capability to break the strongly restricted wall if you have own host out side of the wall.

                        |
Internal (office) | External (internet)
|
+--------+ +----------+ +------+ +--------+
| office | | firewall | | home | | server |
+--------+ +----------+ +------+ +--------+
<------------------ ssh --------------------->sshd:443
<-- connect --> http-proxy <-- https:443 --> any
connect <-- tcp --> port

NOTE: If you wanna use this, you should give up hosting https service at port 443 on you external host 'home'.

F.Y.I.

Difference between SOCKS versions.

SOCKS version 4 is first popular implementation which is documented here. Since this protocol provide IP address based requesting, client program should resolve name of outer host by itself. Version 4a (documented here) is enhanced to allow request by hostname instead of IP address.

SOCKS version 5 is re-designed protocol stands on experience of version 4 and 4a. There is no compativility with previous versions. Instead, there's some improvement: IPv6 support, request by hostname, UDP proxying, etc.

Configuration to use HTTPS

Many http proxy servers implementation supports https CONNECT method (SLL). You might add configuration to allow using https. For the example of DeleGate ( DeleGate is a multi-purpose application level gateway, or a proxy server) , you should add https to REMITTABLE parameter to allow HTTP-Proxy like this:

delegated -Pxxxx ...... REMITTABLE='+,https' ...

For the case of Squid, you should allow target ports via https by ACL, and so on.

SOCKS5 Servers

NEC SOCKS Reference Implementation
Reference implementation of SOKCS server and library.
Dante
Dante is free implementation of SOKCS server and library. Many enhancements and modulalized.
DeleGate
DeleGate is multi function proxy service provider. DeleGate 5.x.x or earlier can be SOCKS4 server, and 6.x.x can be SOCKS5 and SOCKS4 server. and 7.7.0 or later can be SOCKS5 and SOCKS4a server.

Specifications

socks4.protocol.txt
SOCKS: A protocol for TCP proxy across firewalls
socks4a.protocol.txt
SOCKS 4A: A Simple Extension to SOCKS 4 Protocol
RFC 1928
SOCKS Protocol Version 5
RFC 1929
Username/Password Authentication for SOCKS V5
RFC 2616
Hypertext Transfer Protocol -- HTTP/1.1
RFC 2617
HTTP Authentication: Basic and Digest Access Authentication

Related Links

Similars

  • Proxy Tunnel -- Proxying command using https CONNECT.
  • stunnel -- Proxy through an https tunnel (Perl script)

Convert .mov to .avi - Linux

I have a digital camera that creates .mov files for videos. It's terrific but I cannot watch the videos (.MOV) that I capture with the camera on our living-room DVD player. However, like many recent DVD players, it will play .avi files. So I use this handy command that I ripped off in its entirety, some time ago. It will make separate .mp3 and avi files for your enjoyment:

$ for fl in YOURMOVFILE.MOV
do
mencoder ${fl} -o ${fl/mov/avi} -oac mp3lame -ovc lavc
mplayer -ao pcm -vo null -vc dummy -dumpaudio -dumpfile ${fl/mov/mp3} ${fl/mov/avi}
#rm ${fl/mov/avi}
done

Output

Of course, you need mplayer and mencoder installed.

ffmpeg is perfectly up to this task as well, although I think mencoder is a little faster. The syntax that I have been using (specifying a 60FPS frame rate) is the following:

$ ffmpeg -i file-name.mov -g 60 -vcodec msmpeg4v2 -acodec pcm_u8 file-name.avi

This works a charm and really shrinks the file size. My original 17 second clip in its original .mov file format weighed in at 8.5MB. Following conversion the avi clip weighed in at 855.5KB.

Of course, the conversion has a degenerative affect on playback, towit, it might look pretty bad stacked up against the original, but that's what you get. If you know a better way, or better ffmpeg conversion syntax, then hook us all up.

Fedora 11 (Leonidas)

Image:fedora-11-tour.png

Welcome to Fedora 11

Fedora is a Linux-based operating system that provides users with access to the latest free and open source software, in a stable, secure, and easy to manage form. Fedora is the largest of many free software creations of the Fedora Project, a partnership of free software community members from around the globe.

For more general information about the Fedora Project, including goals, values, how to get Fedora, and how to join the global community of contributors, see the Overview page.

Comprehensive release notes for Fedora 11 are also available, which describe the changes in Fedora since the last release, and are full of information for both new and experienced users.

Download Fedora 11

To get a copy of Fedora 11, visit get.fedoraproject.org. Options for direct download and BitTorrent are available.

Fedora 11 Release Overview

Fedora 11 continues the Fedora Project's tradition of the Four Foundations: Freedom, Friends, Features, First. Freedom represents dedication to free software and content. Friends represents the strength of our community. Features represents our commitment to excellence. First represents our commitment to innovation.

Fedora's hallmarks are technical excellence and innovation. Fedora 11 is packed with tons of new features across the spectrum from casual desktop user to hardcore hacker. Additionally, Fedora 11 offers a very good technical preview of features that may appear in the upcoming version of Red Hat Enterprise Linux. Fedora 11 showcases a new default filesystem in ext4, a 20 second startup, and the latest GNOME, KDE and XFCE releases. Firefox 3.5 and Thunderbird 3 latest pre-releases are available as well. Fedora 11 features Presto, a yum plugin that reduces bandwidth consumption drastically by downloading only binary differences between updates. It also features Openchange for interoperability with Microsoft Exchange. There are new security enhancements, improved and upgraded development tools, and cutting edge features in areas such as virtualization.

For a complete list of Fedora 11 features see the complete Fedora 11 feature list.

For some more detailed coverage of features, you can see either the Fedora 11 talking points for a high level overview or take a look at the Fedora 11 in-depth feature profiles for more detailed discussion on specific features.

Screenshot Tour

The Fedora 11 screenshot tour includes what's new and exciting in pictorial form. Enjoy the new KDE 4.2.2, Firefox 3.5,Thunderbird 3 or the new PulseAudio volume controls.

Fedora 11 Multimedia

In anticipation of the release there have been several podcasts and interviews produced as well as other multimedia such as screencasts. You can find links to those below.

Podcasts

A number of podcasts on topics such as a General Overview of F11 and specific features like Presto, Kernel Mode Setting, and PackageKit can be found at the Fedora 11 podcasts page.

Print Interviews

An interview with Lennart Poettring on Fedora 11's Volume Control - The Sound of Fedora 11

An interview with Daniel Berrange on upcoming Virtualization improvements in Fedora 11 - Fedora 11: Virtual(ization) Reality

An interview with Bastien Nocera on Fedora 11's Fingerprint Authentication - Fedora 11: Raise Thy Mighty...Finger?

Screencasts

Plymouth (Fedora's graphical boot system) includes a new bootup sequence called "Charge," created by Mike Langlie and Ray Strode. Plymouth has a separate plugin system that allows anyone to create themes such as "Charge" for use on Fedora or other derivative distributions.

Ogg-Theora Video

You can watch this video directly within Firefox 3.1 or higher, such as in Firefox 3.5 provided by Fedora 11, or other HTML 5 capable browsers. Using a different browser that's not HTML 5 capable? You have our sympathies. Try these links:

****************************************************************************

Fedora 11 Upgrade Tutorial

I've already got Fedora 10 and want to upgrade to Fedora 11. How do I upgrade my computer from Fedora Linux 10 to Fedora Linux 11?

Fedora 11 can be directly upgraded over the Internet using the various methods available. Backup all your data (/home and other directories), config file and sql files. Use tools such as rsync or tar to make backup to CD / DVD or other server.

Login as root user to perform upgrade.

WARNING! It is not possible to upgrade directly from Fedora 9 to Fedora 11. To upgrade Fedora 9 to Fedora 11, upgrade to Fedora 10 first. Make sure you backup imporant data before using the information provided below. Also, the yum update step should NOT be run inside a gnome / kdep desktop session/gnome-terminal. It could result in a unusable install when gnome-terminal segfaults during the upgrade. Update should be run in a vty, runlevel 3, or a screen session.

Apply Fedora 10 Patches and Software Updates

Type the following command to apply existing update:
# yum update rpm
# yum -y update
# yum clean all
Reboot the system if a new kernel installed for Fedora 10 (otherwise skip to next step):
# reboot

Upgrade Fedora 10 to Fedora 11

Type the following commands to perform actual upgrade:
# yum install preupgrade
# preupgrade

If you need GUI tool, enter:
# preupgrade-gui

How do I Upgrade Fedora 10 Server?

Backup everything and type the following commands as root user:
# yum -y update
# yum install preupgrade
# preupgrade-cli
# reboot

How Do I Upgrade Fedora 10 Using CD / DVD?

Apply existing patches to fedora 10:
# yum -y update

Backup all required data, config and sql files.

Insert CD / DVD into CDROM and reboot the system. Make sure BIOS is configured to boot from CD / DVD.

To perform an upgrade, select Perform an upgrade of an existing installation. Click Next when you are ready to begin your upgrade.

Are you smart enough to LINUX

Linux may never gain widespread success, that we, the Linux fans want it to, because it's just too complex for the average computer user. Sure, we now have KDE, GNOME, XFCE, and other fancy graphical user interfaces that attempt to mimic Windows and the Mac OS but underneath the shimmering polish, it's Unix and that scares people. I'm not so sure that this is a bad thing.

When I first compared PCs and Macs around 1988, I decided that Mac users would be more efficient at Microsoft Word or drawing pictures than a PC user but the PC user would know far more about computers. This was because the Mac OS protected its user from the underlying workings of the computer whereas the PC did not.

Nowadays, the PC is becoming the "dumbed-down" operating system of the masses and the Mac OS is more for tinkerers. The Mac OS, since the introduction of version 10 (X), is now a blend of FreeBSD (A free, open source operating system like Linux) and Mach64 (NeXT) architecture. Basically the Mac OS is more like Linux than its former self.

I assumed, in those thrilling days of yesteryear, that Mac users weren't as smart as PC users. Basically, if you're dumb (and have a lot of money), you use a Mac. These days I think that PC (Windows) users are the less skilled of the three user types. Each new version of Windows that emerges is smarter than the previous one, the new applications are released without some of the more sophisticated features they once brandished, and our gadgets (with the exception of cell phones) are built with a minimalist design.

This is all to our own detriment.

Think about it. If software companies continue to make smarter operating systems, we'll in turn, get dumber because there will less for us to do and tinker with, fix, and enhance. In essence, our skills will atrophy from lack of use. Then, the software companies, one in particular, will have us where they want us: At their mercy.

I don't want to be in that position. I want my technical skills to remain sharp by working with an operating system that's close to the hardware. I like to configure, enhance, tinker, tweak, and build something that's better than what's handed to me.

The question doesn't mean, "Do you have the required intelligence to use Linux" but rather "Are you smart enough to make the decision to use Linux and keep that technical edge?"
top