Posts Categorized: linux

smbclient: Special Characters and UTF-8

I have a PHP web application that communicates to Windows Shares via the smbclient binary. My problem was that some characters (particularly accented characters such as é ) were not being shown on the PHP page and were even causing lines of output to be omitted. After ensuring the PHP page was outputting UTF8 I… Read more »

Media Streaming on Ubuntu with Mediatomb

mediatomb

Install with:

Amend the /etc/mediatomb/config.xml file. I find the  configuration below works well for all the video types I throw at it. Then access the web interface at http://localhost:49152 logging in with mediatomb/mediatomb and add some video directories to be served. <?xml version=”1.0″ encoding=”UTF-8″?> <config version=”2″ xmlns=”http://mediatomb.cc/config/2″ xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance” xsi:schemaLocation=”http://mediatomb.cc/config/2 http://mediatomb.cc/config/2.xsd”><!– Read /usr/share/doc/mediatomb-common/README.gz section 6 for… Read more »

Exim Troubleshooting

We had a bit of difficulty yesterday with LDAP / Active Directory authentication within Exim. Sending mail via SMTP with authentication was timing out and it looked like a TLS error.

We got to the bottom of the problem by running exim in debug mode as the logs were not giving enough details. Stop… Read more »

Manipulating Image Metadata for Stock Photos

exiftool

On a Linux desktop one thing I miss is the ability to easily add metadata (exif / iptc) to the images I upload to stock photo websites. Adding this metadata makes it much easier to submit the same photo to multiple websites. The ‘File Info’ command in Photoshop does what I want but I haven’t… Read more »

Automounting Netgear ReadyNAS CIFS Shares

I wanted to use Autofs to auto-mount the shares on my Netgear ReadyNAS upon entering specific directories so… Install pre-requisites:

 

Add the line:

 

And added the following lines:

Note that I have used ‘nas’ instead of the nas IP address and I also opted not to use a… Read more »

wine cmd.exe /c echo ‘%ProgramFiles%’ returned empty string

I had this problem today:

When I was trying to run Winetricks:

Until I realised that I was trying to run winetricks as root rather than as my normal unprivileged user. Just in case it helps anyone else.

Testing Proxy.pac Files

I decided to do a bit of checking on the proxy.pac file we were using. I grepped through our Apache access log files to pull out all of the IP addresses accessing the file over the year:

Armed with the list of IP addresses I next fired up pactester. Pactester Pactester is available from… Read more »

Coloring Bash Output

Colour bash shell script output

I wanted to add some colour to the output of my bash shell script and was able to do so with the following – very simple red and green:

Radius with LDAP Authentication

The notes here are a quick howto for using LDAP authentication against Active Directory. It is possible to use Samba/Winbind/Kerberos authentication within Radius too and I may post those notes when I get a chance but for now this is how I implemented it with LDAP. Install required software on CentOS/Red Hat:

Edit the… Read more »

Apache Directory Studio (Softerra Alternative)

I was looking for an alternative to the Windows software ‘Softerra LDAP Browser’  and I stumbled upon Apache Directory Studio. Apache Directory Studio is based on Eclipse and allows browsing to LDAP directories, searching and editing. I tested it with connections to Active Directory, Novell eDirectory and another lesser known LDAP directory. Install Apache Directory… Read more »