Show all users e-mail adresses and aliases

Simple command to list all users adresses and aliases. Nice to get a overview when migrating all users in an organization.

Solve permalinks in WordPress on Ubuntu LAMP

I just moved one of my test sites to a new server. And realized that the permalink structure didnt worked after that. I made sure that the .htaccess files where correct, that mod_rewrite was enabled, but still nothing.

So after some searching i found out that you need to set AllowOverride All in the config for apache.

So, first install mod_rewrite

Then edit the config for your default website.
In Ubuntu 14.04 it is called 000-default.conf.

Paste the following at the bottom of the file (change the directory if you are not using the new default /www/html/ structure(

At last, restart the apache service

Dropbox Dropquest 2012 – Få 1 GB ekstra lagringsplass gratis

Nå kjører Dropbox i gang med en ny DropQuest, dette er et «rebusløp» med en rekke oppgaver man løser ved bruk av dropbox. Gjennomfører du alle oppgavene får du 1 GB ekstra lagringsplass.

Start Dropquest ved å følge denne linken:

Blir det for vanskelig så ligger svarene nedenfor

HAR DU IKKE DROPBOX ENDA? KLIKK HER! 


Chapter 1: 64529 eller 38645 eller 46637
Chapter 2: https://www.dropbox.com/dropquest2012/crane
Chapter 3: SMUDGES
Chapter 4: SOMA
Chapter 5: MAD LIB
Chapter 6:  En av disse tre linkene..

Chapter 7: En av disse tre linkene.

Chapter 8: TRIUMPHANT
Chapter 9: Gå til https://www.dropbox.com/tour/6 og send en dropbox invite til adressen som står der.
Chapter 10: Mexico, Korea eller Argentina
Chapter 11: Southpole
Chapter 12: Gjenopprett Chapter12.txt til en tidligere utgave (via dropbox websiden). Gå deretter til https://www.dropbox.com/help, Trykk så på ikonet (skjoldet) forran «Security and Privacy»
Chapter 13: 
Chapter 14: Gå til http://www.surfpoeten.de/sudoku?s…%29+suchen finn så samme rute som er merket med blått i dropquesten.  Løs så puslespillet slik at brikkene er like som i sudokuløsningen.
Chapter 15: Del en random dropboxmappe med en av disse: savior@dropbox.comflash@dropbox.com, eller boxer@dropbox.com gå så til https://www.dropbox.com/share og trykk så på regnbuen øverst i midten.
Chapter 16: 
Chapter 17: SHANGHAI
Chapter 18: Flytt filene 1 3 6 8 9 til Category 1, og flytt så filene  2 4 5 7 10 til Category 2. Dette må gjøres via webklienten, bruker du dekstopklienten så må du bruke «Repair Dropquest Folder» linken nederst til venstre.
Chapter 19: http://db.tt/94J964 eller http://db.tt/94J964 eller http://db.tt/Q2J9J4
Chapter 20: https://www.dropbox.com/dropquest2012/apollo13
Chapter 21: ABUSIVELY
Chapter 22: FACED eller MACAU eller BADGE eller BASED eller ADAGE
Chapter 23: MACHU PICHHU
Endgame (Chapter 24): COLOSSEUM

Da skal du sitte igjen med 1 GB ekstra plass!

 

Symantec BESR – Recovery point set is disabled

The other day I run into a problem whilst reconfiguring backup jobs on a server with Symantec Backup Exec System Recovery 2010 (BESR).
I had deleted all backup jobs, and was about to create the new ones. Then i noticed that i could not select the «Create a recovery point set» option, I was only allowed to chose «Independent recovery point.
So i tried to restart the service, -didnt work. Rebooted the server, – didnt work.

After a lot of digging I found a post on Symantec support forum. It appears that BESR is storing information about the backup jobs history and schedules located in .pqh and . files in the following folder:
\Documents and Settings\All Users\Application Data\Symantec\Backup Exec System Recovery\History and \Schedule.

When theese files are present, the BESR manager will assume that it allready exist a recovery point set. In my case there was no .pqj files in the /schedule/ folder, so I only deleted the .pqh files in the /history/ folder. Then i restarted the service, and problem was solved.

голые девки – say what?

From time to time i like to check how my vistiors found this site.
Today i found one hit from a Russian searchengine. The search term used was ‘голые девки’
Google translate says «naked girls» 🙂 How this lead to my site is an unanswered question, as I dont have any Russian text here, or anything related to nude girls.

English it is..

Dansker og belgiere har tydeligvis stor interesse for et par av prosjektene mine, men de kan lite norsk.
Tenkte derfor å skrive de teknisk relaterte postene på engelsk fremover. Miljøet for slikt er veldig lite i Norge uansett, og de som forstår dette forstår også engelsk, hvis ikke så er noe veldig galt.

syntax highlighter

Hello world written in php withouth the [ php ] tag:




echo «Hello world!»;
?>

with the [ php ] and [/ php ] tags:


Some large block with C code

#include 
#include 
#include 
#include 
#define rxPin 2
#define txPin 3
#define ONE_WIRE_BUS 5
OneWire oneWire(ONE_WIRE_BUS);
DallasTemperature sensors(&oneWire);
DeviceAddress utesensor = { 0x28, 0x7E, 0xF9, 0x5E, 0x2, 0x0, 0x0, 0x42 }; // loddet på 3.5mm
// DeviceAddress innetemp = { 0x28, 0xF0, 0x12, 0x5F, 0x02, 0x0 , 0x0, 0x9E }; //  på hylla
DeviceAddress innesensor = { 0x28,0x2A,0xDE,0x5E,0x02,0x00,0x00,0x19 }; // I BODEN.
byte mac[] = { 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED };
byte ip[] = { 10, 0, 0, 177 };
byte gw[] = {10,0,0,101};
byte server[] = { 88,87,42,5 }; // gmx.no
byte subnet[] = { 255, 255, 255, 0 };

SoftwareSerial lcdSerial =  SoftwareSerial(rxPin, txPin);
int ledPin = 6;
int avgwatt = 5;
int switchPin = 7;
const int numReadings = 20;
unsigned long period_start;
unsigned long period_length = 57000;
unsigned long period_total;
unsigned long period_stop;
unsigned long run = 0;
int period_average;
int period_counter;
float itemp;
float utemp;

void setup()
{
  Serial.begin(9600);
  pinMode(rxPin, INPUT);
  pinMode(txPin, OUTPUT);
  pinMode(switchPin, INPUT);
  pinMode(ledPin, OUTPUT);
  lcdSerial.begin(9600);
  sensors.begin();
  sensors.setResolution(innesensor, 12);
  sensors.setResolution(utesensor, 12);
}
void loop()
{
  sensors.requestTemperatures(); // Send the command to get temperatures
  lcdcls();
  period_total = 0;
  period_counter = 0;
  period_start = millis();
  period_stop = period_start + period_length;
  if (run > 0) {
     lcdgoTo(0);
     lcdSerial.print(avgwatt);
     lcdSerial.print(" Current.  ");
     lcdgoTo(17);
     lcdSerial.print(period_average);
     lcdSerial.print(" Average.  ");

      }
      else {        // First run.. write no data.
     lcdgoTo(0);
     lcdSerial.print("No data.");
     lcdgoTo(17);
     lcdSerial.print("No data.");

      }

  while( millis()