Forfatterarkiv: mike

Installing an alphaweb server

********************* Setup etch backports: ********************* echo “deb http://www.backports.org/debian etch-backports main contrib non-free” >> /etc/apt/sources.list cat >> /etc/apt/preferences << EOF Package: * Pin: release a=etch-backports Pin-Priority: 999 EOF wget -O – http://backports.org/debian/archive.key | apt-key add – apt-get update *************************** Setup webserver, … Læs resten

Udgivet i Knowledge Base, Linux, Networking, Old Base | Skriv en kommentar

Roku Soundbrigde Streaming fra Icecast

I have to write this down while its fresh in my memory … At the office we have a Roku Soundbridge which is a unit with a lot of potentiale and right now i unleashed just a bit more of … Læs resten

Udgivet i Knowledge Base, Old Base | Skriv en kommentar

Sending SMS From Linux (Sony Ericsson and Gnokii)

the phone should show up in dmesg like: usb 2-1: new full speed USB device using uhci_hcd and address 2 usb 2-1: configuration #1 chosen from 1 choice cdc_acm 2-1:1.1: ttyACM0: USB ACM device cdc_acm 2-1:1.3: ttyACM1: USB ACM device … Læs resten

Udgivet i Knowledge Base, Linux, Old Base | Skriv en kommentar

Simple iptables-firewalling the Debian way

The script is self explanatory, and if you dont understand it go read some newbie-guide to iptables, otherwise place the script in /etc/init.d name it firewall and run: update-rc.d rc.firewall defaults 19 And then you are ready to go 🙂 … Læs resten

Udgivet i Knowledge Base, Linux, Networking, Old Base | Skriv en kommentar

Setting up a CVS repository (pserver)

First we need a fresh Debian 4.0 install – Installation of cvs and cvsd # apt-get install cvs cvsd – You will be asked for the name of the repositories you want to permit access to, here we wrote “mcs” … Læs resten

Udgivet i Knowledge Base, Old Base | Skriv en kommentar

Postgre quickguide

postgres@dev:~$ psql projektstyring Welcome to psql 8.1.9, the PostgreSQL interactive terminal. postgres@dev:~$ createdb projektstyring CREATE DATABASE projektstyring=# create user projektstyring with password ‘kode’; CREATE ROLE projektstyring=# GRANT ALL ON DATABASE projektstyring TO projektstyring; GRANT should be all that you need … Læs resten

Udgivet i Knowledge Base, Old Base, Programmering | Skriv en kommentar

Xini file parser v1.0

<? # Xini parser v1.0 by MC Solutions 2007, all righs reserved /* Samlpe file: menu.xini: !Structure=Text,Url [Menu] Item=”Om firmaet”,”about.php” Item=”Kontakt firmaet”,”contact.php” [Menu2] Item=”Bestil”,”order.php” Item=”Log ind”,”login.php”,”nisse”,”fisk” [forside] Titel=”Bla bla bla” BestilLink=”Bla bla bla” EOF !Structure describes the name of the … Læs resten

Udgivet i Knowledge Base, Old Base, Programmering | Skriv en kommentar

Generating java code from JavaDoc HTML

Cut’n’paste the method summary to the created class. Use this search and replace in VS.NET: Search: ^{[^\)]*}\) \n:b*{[^\n]*}$ Replace: \n/**\n * \2\n */\npublic \1) { } For interfaces use this replace: \n/**\n * \2\n */\n\1); Strip blank comment blocks with: … Læs resten

Udgivet i Knowledge Base, Old Base, Programmering | Skriv en kommentar

Get enums fra mysql in php

PRIVATE function GetEnums($table,$field) { $dat=mysql_fetch_array(mysql_query(“show columns from `$table` like ‘$field’;”,$this->MysqlResource)); return(preg_split(“/’|,|enum|\(|\)/”,$dat[‘Type’],null,PREG_SPLIT_NO_EMPTY)); }

Udgivet i Knowledge Base, Old Base, Programmering | Skriv en kommentar

SSH Mount in Ubuntu

I did the following, you might not need to do it all: Create mount dir and chown it to the user who needs to access it. Add the following line to fstab: sshfs#USERNAME@SERVER:/PATH /mnt/MOUNTPOINT fuse defaults,noauto,user,uid=mike,gid=mike,allow_other,reconnect,transform_symlinks 0 0 For automated … Læs resten

Udgivet i Knowledge Base, Linux, Old Base | Skriv en kommentar