Posted by aionman on Jan 19, 2011 in
Zimbra
Various Zimbra services use passwords stored in localconfig when connecting to ldap and mysql. If these passwords
Updating LDAP Passwords
It is necessary to run the password update commands as the zimbra user.
# su - zimbra
In ZCS 5.0.x
Command Usage: /opt/zimbra/bin/zmldappasswd [-h] [-r] [-p] [-l] newpassword
-h: display this help message
-a: change ldap_amavis_password
-l: change ldap_replication_password
-n: change ldap_nginx_password
-p: change ldap_postfix_password
-r: change ldap_root_passwd
Only one of a, l, n, p, or r may be specified
Without options zimbra_ldap_password is changed
Make sure that slapd is running. Note that the actual process id (pid) will vary.
$ ldap status
slapd running pid: 32266
Update the ldap root password.
$ zmldappasswd -r newrootpass
Update the zimbra ldap password.
$ zmldappasswd newpass
If necessary, update the password for other ldap users (amavis, replication, nginx, postfix).
In ZCS 4.5.x
Stop zimbra services.
# su - zimbra
$ zmcontrol stop
Verify that all Zimbra services are stopped.
$ ps auxww | grep zimbra
Now we can reset the passwords. Note: In versions of ZCS up to 4.5.x the zimbra ldap password must be the same as the ldap root password.
Update the ldap root password.
$ zmldappasswd --root newpass
Update the zimbra ldap password.
$ zmldappasswd newpass
Updating Mailbox MySQL Database Passwords
It is necessary to run the password update commands as the zimbra user.
# su - zimbra
Make sure the mailbox mysql database is running. Note that the actual process id (pid) will vary.
$ mysql.server status
mysql is running with pid 23830
If that fails to find a running mysql, verify that the mailbox mysqld does not appear in the process list, and then start it.
$ ps a | grep mysqld.*my.cnf
$ mysql.server start
Update the mysql root password.
$ zmmypasswd --root newrootpass
Update the zimbra mysql password.
$ zmmypasswd newpass
Updating Logger MySQL Database Passwords
It is necessary to run the password update commands as the zimbra user.
# su - zimbra
Make sure the logger mysql database is running. Note that the actual process id (pid) will vary.
$ logmysql.server status
mysql is running with pid 23830
If that fails to find a running mysql, verify that the mailbox mysqld does not appear in the process list, and then start it.
$ ps a | grep mysqld.*my.logger.cnf
$ logmysql.server start
Update the logger mysql root password.
$ zmmylogpasswd --root newrootpass
Update the logger zimbra mysql password.
$ zmmylogpasswd newpass
Posted by aionman on Jan 6, 2011 in
Ubuntu
Ubuntu 10.04 vnc-based login server
This recipe is for setting up a VNC login server. This allows you to use a VNC client to access a full GUI on a remote server. If instead you want to get VNC access to your desktop (or share with other users) you need to enable remote desktop.
VNC connections are not encrypted so if you connect directly to the VNC server any login details will be sent in the clear.
Install the required packages:
sudo apt-get install vnc4server xinetd gdm
Restrict GDM to only listening to localhost by adding the following to/etc/hosts.allow:
gdm: ip6-localhost
Enable XDMCP in GDM by setting up /etc/gdm/custom.conf as:
# GDM configuration storage
[daemon]
[security]
[xdmcp]
Enable=true
HonorIndirect=false
# following line fixes a problem with login/logout
DisplaysPerHost=2
[greeter]
[chooser]
[debug]
Create a new xinetd service /etc/xinetd.d/Xvnc (adjust geometry to get different screen sizes):
service Xvnc
{
type = UNLISTED
disable = no
socket_type = stream
protocol = tcp
wait = no
user = nobody
server = /usr/bin/Xvnc
server_args = -inetd -query ip6-localhost -geometry 1280x800 -depth 16 -cc 3 -once -SecurityTypes=none
port = 5901
}
Restart gdm (which will close any current logins!) and xinetd:
sudo service gdm restart
sudo /etc/init.d/xinetd restart
You can then connect to the VNC server using:
vncviewer localhost:5901
Posted by aionman on Dec 17, 2010 in
Windows 2008
When viewing Server Manager on Windows Server 2008 we are getting a Roles: Error with error details of unexpected error refreshing Server Manager and an exception code: 0x800B0100.
Solution:
1. Download System Update Readiness Tool for Windows Server 2008/Vista – http://support.microsoft.com/?kbid=947821
x86
http://www.microsoft.com/downloads/details.aspx?FamilyID=6d9ece65-3820-4583-85f5-7e2a5799b3ba&DisplayLang=en
x64
http://www.microsoft.com/downloads/details.aspx?FamilyID=32978546-8108-408f-b78e-0e95eff14c92&DisplayLang=en
2. The System Update Readiness Tool creates a log file with any issues the tool found or fixed.
The log file is located under: c:\windows\logs\CBS\CheckSUR.log
Example:
=================================
Checking System Update Readiness.
Binary Version 6.1.7600.20822
Package Version 10.0
2010-12-17 17:39
Checking Windows Servicing Packages
Checking Package Manifests and Catalogs
(f) CBS MUM Corrupt 0×00000000 servicing\Packages\Package_for_KB2388210_RTM~31bf3856ad364e35~amd64~~6.1.1.1.mum Expected file name Microsoft-Windows-Foundation-Package~31bf3856ad364e35~amd64~~6.1.7600.16385.mum does not match the actual file name
Checking Package Watchlist
Checking Component Watchlist
Checking Packages
Checking Component Store
Summary:
Seconds executed: 343
Found 1 errors
CBS MUM Corrupt Total count: 1
Unavailable repair files:
servicing\packages\Package_for_KB2388210_RTM~31bf3856ad364e35~amd64~~6.1.1.1.mum
servicing\packages\Package_for_KB2388210_RTM~31bf3856ad364e35~amd64~~6.1.1.1.cat
Based on the example this means that we are missing 1 MUM packages under c:\windows\servicing\packages
3. We locate the failed KB Update KB2388210 in this example which will be different for everybody and we download it on our system
4. We rename it from .msu to .cab and we extract it to get our missing files
5. We locate the missing files and we copy them to a new folder. Most of the times at least 1 file can not be found so we have to rename the update.mum and update.cat to the missing file name
6. We select Properties of c:\windows\servicing\Packages and under Security tab we click on Advanced. On Owner tab we click on Edit and change the owner from TrustedInstaller to our account and then OK to return back to Packages Properties
7. Under Security Tab we click on Edit so we can add our account with Full control
8. Now we copy the missing files to c:\windows\servicing\Packages
9. We rerun the update until the log file does not report any more missing files
* Do not forget to assign the Package permissions back to NT SERVICE\TrustedInstaller after you finish with the updates.
Posted by aionman on Dec 1, 2010 in
Linux,
Networking
Installation Notes
Broadcom tg3 Linux Driver
Version 3.57b
04/28/2006
Broadcom Corporation
16215 Alton Parkway,
Irvine, CA 92619-7013
Copyright (c) 2004, 2005, 2006 Broadcom Corporation
All rights reserved
Table of Contents
=================
Introduction
Limitations
Packaging
Installing Source RPM Package
Building Driver From TAR File
Driver Settings
Driver Defaults
Unloading and Removing Driver
Driver Messages
Introduction
============
This file describes the tg3 Linux driver for the Broadcom NetXtreme
10/100/1000 Mbps PCI/PCI-X/PCI Express Ethernet Network Controllers.
The latest driver is in the latest 2.6 Linux kernel. It can also be
downloaded from http://www.broadcom.com as a source package, but is
generally not necessary to do so if you are using the latest 2.6
upstream kernel from http://www.kernel.org or one of the latest
vendor kernels from Red Hat, SuSE, or others.
The tg3 driver from the Broadcom package is almost identical to the
tg3 driver in the latest 2.6 upstream Linux kernel. It includes some
additional kernel compatible code to allow it to compile on older 2.6
and some 2.4 kernels. The version number is also similar but generally
has a one letter suffix at the end, (e.g. 3.55b) to distinguish it from
the in-kernel tg3 driver.
The next few sections on packaging, compiling, and installation apply
mostly to the Broadcom driver package only.
Limitations
===========
The current version of the driver has been tested on 2.4.x kernels starting
from 2.4.24 and all 2.6.x kernels. The driver may not compile on kernels
older than 2.4.24. Testing is concentrated on i386 and x86_64 architectures.
Only limited testing has been done on some other architectures such as
powerpc and sparc64.
Minor changes to some source files and Makefile may be needed on some
kernels.
Packaging
=========
To replace an older previously installed or in-kernel tg3 driver, follow
the instructions below.
The driver package from http://www.broadcom.com is released in two packaging
formats: source RPM and compressed tar formats. The file names for the two
packages are tg3-<version>.src.rpm and tg3-<version>.tar.gz respectively.
Identical source files to build the driver are included in both packages.
Installing Source RPM Package
=============================
The following are general guidelines for installing the driver.
1. Install the source RPM package:
rpm -ivh tg3-<version>.src.rpm
2. CD to the RPM path and build the binary driver for your kernel:
cd /usr/src/{redhat,OpenLinux,turbo,packages,rpm ..}
rpm -bb SPECS/tg3.spec
or
rpmbuild -bb SPECS/tg3.spec (for RPM version 4.x.x)
Note that the RPM path is different for different Linux distributions.
3. Install the newly built package (driver and man page):
rpm -ivh RPMS/<arch>/tg3-<version>.<arch>.rpm
<arch> is the architecture of the machine, e.g. i386:
rpm -ivh RPMS/i386/tg3-<version>.i386.rpm
Note that the –force option may be needed on some Linux distributions
if conflicts are reported.
The driver will be installed in the following path:
2.4.x kernels:
/lib/modules/<kernel_version>/kernel/drivers/net/tg3.o
2.6.x kernels:
/lib/modules/<kernel_version>/kernel/drivers/net/tg3.ko
4. Load the driver:
insmod tg3.o
or
insmod tg3.ko (on 2.6.x kernels)
or
modprobe tg3
5. To configure network protocol and address, refer to various Linux
documentations.
Building Driver From TAR File
=============================
The following are general guidelines for installing the driver.
1. Create a directory and extract the files:
tar xvzf tg3-<version>.tar.gz
2. Build the driver tg3.o (or tg3.ko) as a loadable module for the
running kernel:
cd src
make
3. Test the driver by loading it:
insmod tg3.o
or
insmod tg3.ko (on 2.6.x kernels)
or
insmod tg3
4. Install the driver:
make install
See RPM instructions above for the location of the installed driver.
5. To configure network protocol and address, refer to various Linux
documentations.
Driver Settings
===============
This and the rest of the sections below apply to both the in-kernel tg3
driver and the tg3 driver package from Broadcom.
Driver settings can be queried and changed using ethtool. The latest ethtool
can be downloaded from http://sourceforge.net/projects/gkernel if it is not
already installed. The following are some common examples on how to use
ethtool. See the ethtool man page for more information. ethtool settings do
not persist across reboot or module reload. The ethtool commands can be put
in a startup script such as /etc/rc.local to preserve the settings across a
reboot.
1. Show current speed, duplex, and link status:
ethtool eth0
2. Change speed, duplex, autoneg:
Example: 100Mbps half duplex, no autonegotiation:
ethtool -s eth0 speed 100 duplex half autoneg off
Example: Autonegotiation with full advertisement:
ethtool -s eth0 autoneg on
Example: Autonegotiation with 100Mbps full duplex advertisement only:
ethtool -s eth0 speed 100 duplex full autoneg on
3. Show flow control settings:
ethtool -a eth0
4. Change flow control settings:
Example: Turn off flow control
ethtool -A eth0 autoneg off rx off tx off
Example: Turn flow control autonegotiation on with tx and rx advertisement:
ethtool -A eth0 autoneg on rx on tx on
Note that this is only valid if speed is set to autonegotiation.
5. Show offload settings:
ethtool -k eth0
6. Change offload settings:
Example: Turn off TSO (TCP segmentation offload)
ethtool -K eth0 tso off
7. Get statistics:
ethtool -S eth0
8. Perform self-test:
ethtool -t eth0
Note that the interface (eth0) must be up to do all tests.
9. See ethtool man page for more options.
Driver Defaults
===============
Speed : Autonegotiation with all speeds advertised
Flow control : Autonegotiation with rx and tx advertised
MTU : 1500 (range 46 – 9000)
Some chips do not support jumbo MTUs bigger than
1500
Rx Ring Size : 200 (range 0 – 511)
Some chips are fixed at 64
Rx Jumbo Ring Size : 100 (range 0 – 255)
Not all chips support the jumbo ring, and some
chips that support jumbo frames do not use the
jumbo ring.
Tx Ring Size : 511 (range (MAX_SKB_FRAGS+1) – 511)
MAX_SKB_FRAGS varies on different kernels and
different architectures. On a 2.6 kernel for
x86, MAX_SKB_FRAGS is 18.
Coalesce rx usecs : 20 (range 0 – 1023)
Coalesce rx usecs irq : 20 (range 0 – 255)
Coalesce rx frames : 5 (range 0 – 1023)
Coalesce rx frames irq : 5 (range 0 – 255)
Coalesce tx usecs : 72 (range 0 – 1023)
Coalesce tx usecs irq : 20 (range 0 – 255)
Coalesce tx frames : 53 (range 0 – 1023)
Coalesce tx frames irq : 5 (range 0 – 255)
Coalesce stats usecs : 1000000 (aprox. 1 sec.)
Some coalescing parameters are not used or have
different defaults on some chips
MSI : Enabled (if supported by the chip and passed
the interrupt test)
TSO : Enabled on newer chips that support TCP segmentation
offload in hardware.
Unloading and Removing Driver
=============================
To unload the driver, use ifconfig to bring down all eth# interfaces opened
by the driver, then do the following:
rmmod tg3
Note that on 2.6 kernels, it is not necessary to bring down the eth#
interfaces before unloading the driver module.
If the driver was installed using rpm, do the following to remove it:
rpm -e tg3
If the driver was installed using make install from the tar file, the driver
tg3.o (or tg3.ko) has to be manually deleted from the system. Refer
to the section “Installing Source RPM Package” for the location of the
installed driver.
Driver Messages
===============
The following are the most common sample messages that may be logged in the file
/var/log/messages. Use dmesg -n <level> to control the level at which messages
will appear on the console. Most systems are set to level 6 by default. To see
all messages, set the level higher.
Driver signon:
————-
tg3.c:v3.53c (Mar 13, 2006)
NIC detected:
————
eth0: Tigon3 [partno(BCM95704CA40) rev 2002 PHY(5704)] (PCI:66MHz:64-bit) 10/100/1000BaseT Ethernet 00:10:18:04:3e:64
eth0: RXcsums[1] LinkChgREG[0] MIirq[0] ASF[0] Split[0] WireSpeed[1] TSOcap[1]
eth0: dma_rwctrl[763f0000] dma_mask[64-bit]
Link up and speed indication:
—————————-
tg3: eth0: Link is up at 1000 Mbps, full duplex.
tg3: eth0: Flow control is on for TX and on for RX.
Link down indication:
——————–
tg3: eth0: Link is down.
Posted by aionman on Oct 11, 2010 in
ipad
The iPad is a first generation product. And you know what that means – we’re going to see some bugs and glitches hidden throughout the tablet’s hardware and software. The first of those not-fully-ironed-out bugs seems to be related to the way the device charges. According to reports, and confirmation on our own fleet of iPads, the Apple tablet has issues when trying to top off its integrated battery. Instead of charging the battery, certain charging scenarios will result in a “Not Charging” indicator being displayed in the top-right corner of the display.
It turns out that the new Apple gadget won’t charge through USB ports
on non-Apple computers. Here’s what we know so far through reports and our own tests:
- iPad
charges just fine through the wall charging brick and accompanying USB data cable
- It charges just fine when connected to USB ports on iMac, MacBook Pro
- It does not charge correctly when connected to a PC
- It does not charge correctly when connected to an older MacBook Pro (pre-Unibody)
- It does not charge through USB hubs, regardless of what the hub is connected to (PC or Mac)
What’s going on here? Well, Apple apparently designed the iPad to be charged through its own wall charger. It was designed to be charged only through high-power USB 2.0 ports, but Apple also mentions in their tech notes that some USB 2.0 ports do not provide the necessary power to charge the battery.
This may be the reason why:-
Ok, let’s do the math:
The iPad has a 25Wh battery, it can run for about 10 hours, to it draws about 2.5 watts.
The iPad charger can provide 10 watts of power, so the iPad has its 2.5 watts for running and can put 7.5 watts into the battery. If it’s sleeping it can put, I’d guess, about 9.5 watts into the battery.
The iPhone charger and newer Macs can provide 5 watts of power. That’s 2.5 resp. 4.5 watts for the battery.
A standard USB port as it can be found about anywhere can provide 2.5 watts. So a running iPad has what left for the battery? Um, that’s hard. What is 2.5 minus 2.5…?
Posted by aionman on Oct 7, 2010 in
Linux,
Ubuntu
Pre-requisites.
I don’t know how much of it its really needed, but I install the whole Sun’s Java 6 packages,
$ sudo apt-get install sun-java6-jdk sun-java-6-jre sun-java6-pluging
sun-java6-source sun-java6-bin
For sure you’ll need the jdk and plugin one… If your internet connection is slow you might try installing these two first and try the above command.
Configuration of Java for Mozilla.
For enable Java plugin on Firefox 3.6,
$ sudo update-alternatives --install /usr/lib/mozilla/plugins/libjavaplugin.so \
mozilla-javaplugin.so /usr/lib/jvm/java-6-sun/jre/lib/i386/libnpjp2.so 50
Now it’s time to restart your browser.
For checking that the plugin is enabled, open your Firefox browser and type
about:plugins
in the address line, there must be the Java application enabled.