Remove leading slash in URLs – Apache

I’ve been trying to remove the trailing slashes from all URLs. For example, I want the following URLs to redirect: http://my-site-url.com///test -> http://my-site-url.com/test http://my-site-url.com//test -> http://my-site-url.com/test http://my-site-url.com/test -> http://my-site-url.com/test I’ve tried using the following RedirectMatch rule: RedirectMatch 301 ^//+(.*)$ http://my-site-url.com/$1 However this does not do anything at all. The page does not redirect, and the…

Increase Swap file size that already exists (EC 2 linux)

I created swap file doing this: sudo /bin/dd if=/dev/zero of=/var/swap.1 bs=1M count=4096 sudo /sbin/mkswap /var/swap.1 sudo chmod 600 /var/swap.1 sudo /sbin/swapon /var/swap.1 I would like to increase to 16GB I tried running this command sudo /bin/dd if=/dev/zero of=/var/swap.1 bs=1M count=16384 but got error: /bin/dd: failed to open ‘/var/swap.1’: Text file busy How would I increase…