find -iname "somefile.txt"
Search
Thursday, 8 December 2011
Linux find iname
If you need to quickly find a file or directly but have no idea of case or path, use the following:
Tuesday, 25 October 2011
Macbook Pro - keyboard problem - Missing P!
My friends MBP was playing up, no caps lock or P key functionality, which issed him off...
After lots of searching and PRAM/cache rebuilds discovered it is a hardware problem. The ribbon cable for the keyboard bends as it enters the motherboard connector and stops keys or trackpad working.
To test, power on the MBP by mains, lay it open on the back of it's screen, take out the battery and press your finger on the location shown in red on this photo:
Whilst pressing here, try the keyboard, it should work again!
Not sure of a permanent fix, but a temporary solution is to take a small piece of card or folded sellotape and stick it to this location, put the battery back in and you are good to go!
After lots of searching and PRAM/cache rebuilds discovered it is a hardware problem. The ribbon cable for the keyboard bends as it enters the motherboard connector and stops keys or trackpad working.
To test, power on the MBP by mains, lay it open on the back of it's screen, take out the battery and press your finger on the location shown in red on this photo:
Whilst pressing here, try the keyboard, it should work again!
Not sure of a permanent fix, but a temporary solution is to take a small piece of card or folded sellotape and stick it to this location, put the battery back in and you are good to go!
Monday, 24 October 2011
Exchange 2010 Log Tracking
I've been having grief with Exchange 2010 Tracking Log Explorer, main reason is I cannot easily do wildcard domain searches...
So, if your logs aren't too big and you want to search the physical log files.
1. Open a command prompt (not Powershell) as administrator on your CAS server
2. Go to the following location:
C:\Program Files\Microsoft\Exchange Server\V14\TransportRoles\Logs\MessageTracking
C:\Program Files\Microsoft\Exchange Server\V14\TransportRoles\Logs\MessageTracking
3. Type:
indstr -l "@searchdomain.com" *.log > C:\searchresults.csv
Replacing 'searchdomain.com' with the domain of your choice. Once the process is complete you will have a nice CSV file with all the log entries!
Optimise Mac Lion
- Reset the MBP PRAM - From cold, hold down the 'command' + 'option' + P + R keys, let the system start up and keep them held down until you hear the startup chime twice, when you hear it a second time, let go of the keys and let the system boot.
- Once booted, wait a minute or two, then do a cold shutdown Then do a normal startup and once again a cold shutdown
- Now start up again from cold, this time, hold down the SHIFT key The system will start in cache rebuild mode and will ask you to log in Wait a minute and do a cold shutdown
- Now boot up again normally and your system should be optimised
- Drink coffee
- Now go off and download Onyx for Lion
- http://www.titanium.free.fr/download.php?sid=8bfe2d8127da2b3c2640d2a3a706395d
Tuesday, 7 June 2011
Fix iMac slow boot up times
Apart from the obvious of removing unwanted startup items, try these following fixes:
Reset PRAM and NVRAM
Change some permissions
If you still have trouble give your Mac a good lean using Onyx
http://download.cnet.com/OnyX/3000-18512_4-10653022.html
Reset PRAM and NVRAM
- Shut down Mac
- Turn on Mac
- Hold down CMD, ALT, P and R keys - hold keys down until Mac restarts and you hear the chime
- Let go of keys
Change some permissions
- Open a terminal and type
sudo chown root:wheel/Boot in safe mode to force disk check and clear problem caches
- Shut down the Mac
- Hold down the shift key and turn the Mac on
- Wait until the machine boots
- Log in
- Shut down the Mac and start normally
If you still have trouble give your Mac a good lean using Onyx
http://download.cnet.com/OnyX/3000-18512_4-10653022.html
Thursday, 5 May 2011
Password protect folder in Apache
If you need to setup basic authentication and a protected folder, use the following procedure:
If you now try to access your 'secret' URL you will be prompted for your username and password.
- Setup a basic Apache build with document root set to /htdocs/
- Create the folder you want to protect under /htdocs/ - for example /htdocs/secret/
- Create a text file in your 'secret' folder called - '.htaccess' (no quotes)
- Populate this file with the settings (directives) that you want you 'secret' folder to have, in this case:
AuthType Basic
AuthName "Secret Web"
AuthUserFile /srv/www/.htpasswd
Require valid-user
- Now create a text file called '.htpasswd' (again no quotes) in /srv/www or somewhere other than your Apache document root
- Edit this and using a password encryption generation tool (http://www.tools.dynamicdrive.com/password/) create a username/password combination. It will look something like this:
If you now try to access your 'secret' URL you will be prompted for your username and password.
Friday, 15 April 2011
Set static IP in Bitnami Wordpress
If you need to set a static IP on a Bitnami Wordpress VM stack, follow this procedure:
IPADDR=192.168.1.10 < Your static IP address
NETMASK=255.255.255.0
- Log into the VM
- Copy the existing eth0 configuration to a backup file:
sudo mv /etc/sysconfig/network/ifcfg-eth0 /root/ifcfg-eth0
- Edit the network config file
sudo vi /etc/sysconfig/network/ifcfg-eth0
- Change the following:
IPADDR=192.168.1.10 < Your static IP address
NETMASK=255.255.255.0
- Save the file
- Using vi create the following file:
/etc/sysconfig/network/routes
- with the following content:
default 192.168.2.1 - -(where 192.x.x.x is your default gateway)
- Edit the following file:
/etc/sysconfig/network/config
- and change:
NETCONFIG_DNS_STATIC_SERVERS=""
- to
NETCONFIG_DNS_STATIC_SERVERS="X.X.X.X"(where X.X.X.X is your DNS server)
- Restart networking
sudo /etc/init.d/network restart
Tuesday, 12 April 2011
Fix mouse in Vmware opensuse
Go to:
/lib/udev/rules.d
/lib/udev/rules.d
and edit
69-xorg-vmmouse.rules
to be
ACTION==”add|change”, ENV==”?”, ATTRS==”i8042 AUX port”, KERNEL==”event[0-9]“, PROGRAM=”/usr/bin/vmmouse_detect”, ENV{ID_INPUT.tags}=”vmmouse”
Renew Windows Server 2008 R2 self signed RDP certificate
- Go into control panel/admin tools/iisclick on root of IIS site
- Double click server certficates
- Locate the expired cert and right click/ export to desktop
- Right click and delete the expired cert
- Right click and ‘create new self signed certficate ‘Make sure the ‘friendly name’ is the external DNS name
- go into control panel/admin tools/Remote Desktop Services
- Select ‘remote app manager’
- Click to change digital signature settings and choose your newly created cert
- Recreate and redistribute .RDP files for individual apps
More Linux Permissions
If you need to set folders to 755 and files to 644
sudo chmod -R 644 * ; sudo chmod -R ugo+X *
Monday, 11 April 2011
Vmware - eth0 removed after cloning or moving from Workstation to Esxi
I recently setup a Bitnami WordPress on a local copy of Vmware workstation. This was fine for testing, but I then needed to deploy in a production environment, specifically on Esxi 4.x. The convert ran fine and the VM moved over, but when booting eth0 was not available and hence the stack was inaccessible.
It appears that something happens to the net rules during the conversion process. In order to remove saved rules, just rename the following file and reboot to restore eth0:
Then perform a reboot:
and all should be fine....
It appears that something happens to the net rules during the conversion process. In order to remove saved rules, just rename the following file and reboot to restore eth0:
sudo mv /etc/udev/rules.d/70-persistent-net.rules /etc/udev/rules.d/70-persistent-net.rules.old
Then perform a reboot:
sudo shutdown -r now
and all should be fine....
Sunday, 27 February 2011
Onyx for Mac
If you need to tinker with your Mac, clear logs or caches etc. Rather than sudo'ing in Terminal, give Onyx a try, seems pretty good for a free application.
http://www.titanium.free.fr/
http://www.titanium.free.fr/
Friday, 25 February 2011
Exchange 2010 public folders
If you are trying to replicate content from 2007 to 2010, prepare for some pain. It just doesn't seem to work very consistently.
From Exchange Management Shell on 2007, go to the Exchange/Scripts folder and run:
.\AddReplicaToPFRecursive.ps1 –server my2007server –TopPublicFolder “\” –ServertoAdd
my2010server
This should add all the folder structure to the new 2010 PF database.
Once this is done, run the following to kick the process:
From Exchange Management Shell on 2007, go to the Exchange/Scripts folder and run:
.\AddReplicaToPFRecursive.ps1 –server my2007server –TopPublicFolder “\” –ServertoAdd
my2010server
This should add all the folder structure to the new 2010 PF database.
Once this is done, run the following to kick the process:
Get-publicfolder –identity “\” –recurse |update-publicfolder –server my2007server
You can check on the progress by running the Exchange Management Shell on 2010 and running:
Get-publicfolderstatistics
You might have to keep kicking it though as sometimes it just stops working.
Thunderbolt and others
Take a trip over to Tested - http://www.tested.com/ - to check out all the stuff they pull apart! Also got a feature on new Intel Thunderbolt tech, which looks good.
MO
MO
New MacBook Pros
Well, I'm now sold on Macs. Got myself an iMac and I actually get work done now, instead of booting up and fixing a Windows problem every time. Still use Win 7 though as its not too bad, but OSX seems to always do the job.
http://www.apple.com/uk/macbookpro/
There is also a nice crossover with Linux, so it satisfies the geek in me...
http://www.apple.com/uk/macbookpro/
There is also a nice crossover with Linux, so it satisfies the geek in me...
Subscribe to:
Posts (Atom)