Find ip address of your mac

To find your Mac's IP address, type the following command in Terminal:

ifconfig

Note that it's ifconfig, not ipconfig as you might expect. You will see a bunch of data. You can find your IP address in the en1 section on the line that starts with inet.

If you're not into Terminal, you can also find it by going System Preferences > Network > Advanced > TCP/IP. You will see your IP address listed next to "IPv4 Address."

Setting up a RemoteApp

Creating a new RemoteApp is super simple once your Terminal Server is setup to allow RemoteApps. The TS RemoteApp Manager, which allows you to manage your remote applications, can be found in Control Panel > Administrative Tools > Terminal Services.

Creating a new RemoteApp

  1. Click on the "Add RemoteApp Programs" in the "Actions" menu to the right.
  2. Click next
  3. Select your program
  4. Click next
  5. Click finish

Changing properties on the RemoteApp

The RemoteApp program should show up in the "RemoteApp Programs" list at the bottom. Right-click on the RemoteApp you just created and select "Properties." You can update the location, the alias, and command line arguments.

Creating the RDP file

To create the RDP file that will let users connect to the RemoteApp, select the RemoteApp you just created. A menu should show up in the "Actions" menu specific to your application. Click on "Create .rdp File." You can choose where to save the RDP file, terminal server settings, gateway settings, and certificate settings.

Running ASP.NET applications on Windows 7 machines

You might get a weird error when you publish your .NET site to a Windows 7 machine:

HTTP Error 500.19 - Internal Server Error
The requested page cannot be accessed because the related configuration data for the page is invalid.

Config Error This configuration section cannot be used at this path. This happens when the section is locked at a parent level. Locking is either by default (overrideModeDefault="Deny"), or set explicitly by a location tag with overrideMode="Deny" or the legacy allowOverride="false".  

The fix for this requires a change to applicationHost.config, located at:

%windir%\system32\inetsrv\config\

Change the following section overrideModeDefault values from "Deny" to "Allow" for the system.webServer section in configSections:

<section name="**handlers**" overrideModeDefault="Deny" /> 
<section name="**modules**" allowDefinition="MachineToApplication" overrideModeDefault="Deny" />

You might also get the following 404 error:

The page you are requesting cannot be served because of the extension configuration. If the page is a script, add a handler. If the file should be downloaded, add a MIME map.

Module StaticFileModule
Notification ExecuteRequestHandler
Handler StaticFile
Error Code 0x80070032

You will get this error if your IIS isn't configured to run ASP.NET applications. Go to Control Panel > Programs > Turn Windows features on or off > Internet Information Services > World Wide Web Services > Application Development Features and select "ASP.NET" (which will automatically select all required dependencies).

You might then get this error:

Configuration Error 
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately. 

Parser Error Message: Unrecognized attribute 'targetFramework'. Note that attribute names are case-sensitive.

You will get this error if your website is in .NET 4.0 but the app pool that your website is running under is targeting .NET 2.0. To fix it, go to IIS Manager > Application Pools and select your website's app pool (probably the DefaultAppPool). Click on "Basic Settings" in the "Actions" window to the right and select the right version in the ".NET Framework version" dropdown.

Finally, you mighet get this error:

Handler "PageHandlerFactory-Integrated" has a bad module "ManagedPipelineHandler" in its module list

This can happen if ASP.NET 4.0 installatoin wasn't registered correctly; you can fix it by running the following command from the cmd prompt:

%windir%\Microsoft.NET\Framework\v[version number]\aspnet_regiis.exe -i

You should finally see your website.

Change permissions of multiple files via Mac Terminal

If you want to make a file writable, it's no big deal. Open the "Info" window and update the file permissions at the bottom. However, this approach is painful if you need to change the permissions on multiple files. Enter Terminal:

chmod -R 755 name-of-the-directory-where-files-are-located

If you own the directory and the files, this will work. Otherwise, use:

sudo chmod -R 755 name-of-the-directory-where-files-are-located

The "-R" recursively sets permissions on all files and folders contained within the parent directory. The first number is the access given to the owner; the second number, to the file group's owner; and the third number, to everyone else. Here are the permissions:

  1. Read = 4
  2. Write = 2
  3. Execute = 1
  4. No access = 0

So if you want to give read, write, and execute access, the number you want is 4 + 2 + 1 = 7.

Deleting non-empty folders from Mac Terminal

If you try to delete a non-empty folder from Terminal on your Mac with

rmdir folder-name

you will get the following error:

rmdir: folder-name: Directory not empty. 

The command you want to use is:

rm -r folder-name

Cisco VPN Error 51: Unable to communicate with the VPN subsystem

This error plagues me around every three weeks when I open up my Cisco VPN client on my Mac. The fix for this is straight-forward:

  1. Quit CiscoVPN,
  2. Open Terminal (Applications > Utilities > Terminal), and
  3. Type in the following command:

sudo /System/Library/StartupItems/CiscoVPN/CiscoVPN restart

Type in your password when it asks you for it, and Terminal should restart CiscoVPN, at which point the error should go away.

Happy New Year!

Happy New Year!

Wishing you a very happy new year!

Download the wallpaper

Wordpress Theme: Didactic

Didactic Template Screenshot

Sreejith R. of GFXedit was nice enough to port my Didactic template over to Wordpress. Thanks Sreejith! Go take a look!

1 of 2 pages  1 2 >

On the Side