Showing posts with label Server. Show all posts
Showing posts with label Server. Show all posts

Benefitting from localised servers in Nepal

By // No comments:

Benefiting from localized servers in Nepal

Bandwidth has always been the bottle neck for all the Internet users and also the ISP. As a user we all feel slow while browsing the Internet and downloading files. Also as a service provider we have always thrive to fulfill the bandwidth requirement for the clients.
There's NPIX trying to put local traffic local, as a way helping the us a faster way to browse the internet. My Boss always encourage us to use our own email server that we maintain, keeping our traffic within the country, saving the bandwidth and saving our privacy. NPIX has been proud on making its graph 1GB and aiming to 1.5GB bandwidth consumption. (I am also contributing to reach this target watching YouTube :) Kidding).
Since the Google Cache server has been installed in NTC, most of the Google services has been faster than before and as a matter of fact YouTube has been allowed in our premises (Joking). Most of the NTC ADSL users like me has benefited from it especially on YouTube. We can watch the YouTube movies without buffering (of course not always without buffering) but the bandwidth reaches 740kbps while watching and sometimes reach up to 1Mbps (Mind the small bps here). I am using networx freeware program to check my speed all the time. So most of the time I can watch these movies unless brother complains his Internet became slow. But my eyes are always in the networx small bandwidth meter to check the speed, if they do not reach 700+ I avoid those videos, since they hadn't been loaded in Google cache server, that means nobody has viewed them before and not in cache.

I used to hear friends abroad are watching the movies on their devices using YouTube. And I used to guess when we would do that. It had not been long, just 3 years back. And now we are doing the same, though the Internet speed and growth is not as that of friends abroad. However we cannot sit still without thanking this so called cache server (proxy server), but hey we have already disposed the proxy server at our workplace and nobody thinks of restoring it, who cares. I am just a proxy server configurer not the decision maker.
To save bandwidth, we have heard of Akamai servers installed in Nepal and then Ubuntu Local Repository (Repo). I haven't use this Ubuntu Repo, but will be glad to hear CEntOS or Fedora Repo locally hosted in Nepal. However they haven't been highlighted as Ubuntu. Someday we may be shifting to Ubuntu, don't know. But what I haven't heard is the local sites that keep local bandwidth local that doesn't have to cross the border to cost the price. NPIX tells it is trying to keep local traffic local but doesn't say which sites are local. I only know them when the Internet is in problem and the national sites are working fine but not international sites. So as far as I know the ISPs sites are local. Most of the sites that has .np country level domain name but not hosted inside but outside. So they are a little bit slow than others.
Here is the list of some local sites by myself. If you know more, its worth sharing. I am not listing the sites of ISPs here.
http://np.archive.ubuntu.com/
http://download.com.np/

Snort IDS and Honeyd on Windows XP and 2003

By // No comments:
Lately I have been working on snort IDS for windows. As per requirements to test it in windows, finally got hands on WinIDS. Though there is pre packaged solution on snort IDs with its graphical reporting snorby in Security Onion built in Ubuntu Iso, the preference were given to step by step built up and in windows. WinIds was great. But at last gave the Barnyard error in Windows XP. However such error was not present in windows server 2003. The error was while running barnyard in cmd prompt, it just did not want to run. Next thing I tried to run apache and mysql server that of xampp but just can't. So without further delay just installed fresh apache and mysql. So everything went well on testing in windows server 2003 and made it ready for the deployment.
The next task was to run honeypot in windows. I chose honeyd for windows version. This particular was also incompatible with windows xp. "WinHoneyd is NOT compatible with Windows XP SP2. Microsoft recommended solution:server 2003" one of the experts says in "Experts Exchange". So in favor of server 2003, gave up for Windows XP. I will publish further results after testing.

Koha Installation Offline in Centos 6.0

By // No comments:

Koha Installation Offline in CEntOS 6.0

Installing Koha in online environment is pretty simpler and easier than offline. All the dependencies are needed to be downloaded first, and finding the dependencies for me really took long. Finally below is the way I got through. All the required files and dependencies are directory listed here, except the ISO of Centos 6. I will be adding all file in single zip soon.

Install Centos 6.0

Centos Desktop minimal edition was choosen with the customizati0n and added the following packages:

Applications: Emacs, Graphics -> ImageMagick

Base: Perl

Databases: MySQL Client, MySQL Server

Development: Additional Development -> libxslt-devel, tcp_wrappers-devel

Languages: Nepali if needed

Servers: Print Server, Email Server

Web Services: PHP Support -> php-mysql, Web Server -> all Perl modules



Selinux and firewall are disabled in the system.

Disable selinux
setenforce 0

Turn off firewall
service iptables stop
service ip6tables stop

To disables firewall service
chkconfig iptables off
chkconfig ip6tables off

Turning mysql and apache as service
chkconfig mysqld on
chkconfig httpd on

Copy the repo file for CENTOS repo, here I have disabled the internet CENTOS repo so our system will not spend its time on searching the installation file in the internet.
cp CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo

Copy the repo file for cdrom, here I have added the location of the Centos 6 CDROM and enabled it
cp CentOS-Media.repo /etc/yum.repos.d/CentOS-Media.repo

Now creating our own local repo server for the installation of some packages necessary for koha
yum -y --nogpgcheck localinstall /media/CentOS_6.0_Final/Packages/createrepo-0.9.8-4.el6.noarch.rpm
mkdir /var/myrepo
cp myrepo/* /var/myrepo/
createrepo /var/myrepo
cp myrepo.repo /etc/yum.repos.d/myrepo.repo

Now installing the files from our local repo that are needed by koha

yum -y install libyaz libyaz-devel perl-CPAN perl-CPAN-Meta-YAML gcc GraphicsMagick-perl perl-YAML

Fix the GraphicsMagic installationcd /usr/lib/perl5/auto/Graphics/Magick
mv Magick.so Magick-0.so
ld -share -o Magick.so `pwd`/Magick-0.so /usr/lib/libGraphicsMagick.so.3.6.0



Unpack koha
tar zxf koha-3.06.03.tar.gz
cd koha-3.06.03
perl koha_perl_deps.pl -m | grep 'Yes' | sed -e 's/::/-/g' | awk '{print "yum -y install perl-"$1}' > perl-pkgs-install

sh perl-pkgs-install

It will install the perl modules for the koha from our local repo and cdrom repo.

But there are still some perl modules which are not available in rpm, and need to be installed from the source file.

cd perlpkg

run the commands from the files
11cI
12cI
13cI
14cI
15cI
16cI

Don’t run all of them at once since we won’t be able to see the errors if any.

From the unzipped koha directory run
perl koha_perl_deps.pl -m | grep 'Yes' | awk '{print "cpan -i "$1}' > perl-modules-install
sh perl-modules-install

Cat perl-modules-install

All the necessary perl modules must have been installed

Set up MySQL
[mysqld]
default-character-set=utf8
character-set-server=utf8
skip-character-set-client-handshake

Restart the Mysql daemon

service mysqld restart

Secure mysqld installation.  Follow the prompts and set a root password
/usr/bin/mysql_secure_installation

Create koha database.  Give it a password other than 'kohakoha'
mysqladmin -u root -p create koha
mysql -u root –p
grant all privileges on koha.* to kohaadmin@localhost identified by 'kohakoha';
flush privileges ;
exit

groupadd koha
useradd koha -s /bin/false -d /usr/share/koha -g koha -M



Install KOHA
cd into KOHA installation directory and type
perl Makefile.PL
make
make install

vi /etc/profile.d/koha.tcsh
setenv KOHA_CONF /etc/koha/koha-conf.xml
setenv PERL5LIB /usr/share/koha/lib

vi /etc/profile.d/koha.sh
export KOHA_CONF=/etc/koha/koha-conf.xml
export PERL5LIB=/usr/share/koha/lib

Set up HTTPD
ln -s /etc/koha/koha-httpd.conf /etc/httpd/conf.d/
vi /etc/httpd/conf/httpd.conf
Listen 8080



Go to http://localhost:8080/ to set up the admin interface

Your might have to edit etc/koha/koha-conf.xml for the corret kohaadmin and password (here kohakoha)

Reference:

http://wiki.koha-community.org/wiki/Koha_3.6_on_Centos_6.2_i386

Deploying Active Directory with DNS (linux) in Mixed Environment

By // No comments:

Deploying Active Directory with DNS (Linux) in Mixed Environment

Integrating Active Directory with the Linux as primary DNS Server Lately I was working on integrating the newly configuring Windows 2003 Active Directory with the old running DNS server which was running on Linux. After a day or two searching on the internet I finally found a way to integrate the windows and Linux together.

Generally we install DNS server into an Active Directory. The separation might have been far easier if the DNS server had been the Windows Server itself, but some tweaks were required when the server was Linux.

The Linux DNS server was far old running and the new Active Directory was to integrate to it. So the active directory was installed in the windows 2003 server with the domain name adtest.dipes.com.np and the full name of this computer being dc.adtest.dipes.com.np

The preferred dns of the server itself was like that of others and the clients, e.g. 192.168.40.2 (the ip of Linux DNS server)
The windows server (domain controller) ip was 192.168.40.13

Then inspecting the netlogon.dns file, the following lines of codes of database were written in the dns database file of Linux (dipes.com.np zone file)


dc.adtest IN A 192.168.40.13


_ldap._tcp.adtest.dipes.com.np. SRV 0 0 389 dc.adtest.dipes.com.np.
_kerberos._tcp.adtest.dipes.com.np. SRV 0 0 88 dc.adtest.dipes.com.np.
_ldap._tcp.dc._msdcs.adtest.dipes.com.np. SRV 0 0 389 dc.adtest.dipes.com.np.
_kerberos._tcp.dc._msdcs.adtest.dipes.com.np. SRV 0 0 88 dc.adtest.dipes.com.np.

And this was what looked in the netlogon.dns file in windows server
adtest.dipes.com.np. 600 IN A 192.168.40.13
_ldap._tcp.adtest.dipes.com.np. 600 IN SRV 0 100 389 dc.adtest.dipes.com.np.
_ldap._tcp.Default-First-Site-Name._sites.adtest.dipes.com.np. 600 IN SRV 0 100 389 dc.adtest.dipes.com.np.
_ldap._tcp.pdc._msdcs.adtest.dipes.com.np. 600 IN SRV 0 100 389 dc.adtest.dipes.com.np.
_ldap._tcp.gc._msdcs.adtest.dipes.com.np. 600 IN SRV 0 100 3268 dc.adtest.dipes.com.np.
_ldap._tcp.Default-First-Site-Name._sites.gc._msdcs.adtest.dipes.com.np. 600 IN SRV 0 100 3268 dc.adtest.dipes.com.np.
_ldap._tcp.359ce6bb-ad7c-46c9-8cb3-ee36d2c72f5c.domains._msdcs.adtest.dipes.com.np. 600 IN SRV 0 100 389 dc.adtest.dipes.com.np.
gc._msdcs.adtest.dipes.com.np. 600 IN A 192.168.40.13
fc3d8251-738c-402d-9ba1-33f2402923eb._msdcs.adtest.dipes.com.np. 600 IN CNAME dc.adtest.dipes.com.np.
_kerberos._tcp.dc._msdcs.adtest.dipes.com.np. 600 IN SRV 0 100 88 dc.adtest.dipes.com.np.
_kerberos._tcp.Default-First-Site-Name._sites.dc._msdcs.adtest.dipes.com.np. 600 IN SRV 0 100 88 dc.adtest.dipes.com.np.
_ldap._tcp.dc._msdcs.adtest.dipes.com.np. 600 IN SRV 0 100 389 dc.adtest.dipes.com.np.
_ldap._tcp.Default-First-Site-Name._sites.dc._msdcs.adtest.dipes.com.np. 600 IN SRV 0 100 389 dc.adtest.dipes.com.np.
_kerberos._tcp.adtest.dipes.com.np. 600 IN SRV 0 100 88 dc.adtest.dipes.com.np.
_kerberos._tcp.Default-First-Site-Name._sites.adtest.dipes.com.np. 600 IN SRV 0 100 88 dc.adtest.dipes.com.np.
_gc._tcp.adtest.dipes.com.np. 600 IN SRV 0 100 3268 dc.adtest.dipes.com.np.
_gc._tcp.Default-First-Site-Name._sites.adtest.dipes.com.np. 600 IN SRV 0 100 3268 dc.adtest.dipes.com.np.
_kerberos._udp.adtest.dipes.com.np. 600 IN SRV 0 100 88 dc.adtest.dipes.com.np.
_kpasswd._tcp.adtest.dipes.com.np. 600 IN SRV 0 100 464 dc.adtest.dipes.com.np.
_kpasswd._udp.adtest.dipes.com.np. 600 IN SRV 0 100 464 dc.adtest.dipes.com.np.
ForestDnsZones.adtest.dipes.com.np. 600 IN A 192.168.40.13
_ldap._tcp.ForestDnsZones.adtest.dipes.com.np. 600 IN SRV 0 100 389 dc.adtest.dipes.com.np.
_ldap._tcp.Default-First-Site-Name._sites.ForestDnsZones.adtest.dipes.com.np. 600 IN SRV 0 100 389 dc.adtest.dipes.com.np.
DomainDnsZones.adtest.dipes.com.np. 600 IN A 192.168.40.13
_ldap._tcp.DomainDnsZones.adtest.dipes.com.np. 600 IN SRV 0 100 389 dc.adtest.dipes.com.np.
_ldap._tcp.Default-First-Site-Name._sites.DomainDnsZones.adtest.dipes.com.np. 600 IN SRV 0 100 389 dc.adtest.dipes.com.np.

The next step was the finally joining the client with the domain controller with its previous old settings of preferred dns being same (i.e. 192.168.40.2)