Author Archives: admin

QNAP USB external 3tb drive does not work

This is because you must use parted instead of fdisk to format the drive. parted /dev/sdta (parted) mklabel gpt mklabel gpt Warning: The existing disk label on /dev/sdta will be destroyed and all data on this disk will be lost. … Continue reading

Posted in Linux | Comments Off on QNAP USB external 3tb drive does not work

How to fix postgres sequences that are causing integrity errors.

Save this to a sql file: SELECT ‘SELECT SETVAL(‘ ||quote_literal(quote_ident(S.relname))|| ‘, MAX(‘ ||quote_ident(C.attname)|| ‘)+1) FROM ‘ ||quote_ident(T.relname)|| ‘;’ FROM pg_class AS S, pg_depend AS D, pg_class AS T, pg_attribute AS C WHERE S.relkind = ‘S’ AND S.oid = D.objid AND … Continue reading

Posted in postgres | Comments Off on How to fix postgres sequences that are causing integrity errors.

How to see currently executing queries in postgres 9.2

SELECT query,xact_start,query_start FROM pg_stat_activity;

Posted in postgres | Comments Off on How to see currently executing queries in postgres 9.2

Force a URL to HTTPS using Kemp Loadmaster and Nginx

On the Kemp Loadmaster, do a request header modification, adding the HTTPS: on header. View/Modify Services Click the “Modify” button on  your port 443 service you have already set up Under Advanced Properties,  click Show Header Rules under HTTP Header … Continue reading

Posted in Kemp, Linux, nginx | Comments Off on Force a URL to HTTPS using Kemp Loadmaster and Nginx

git push error: RPC failed; result=22, HTTP code = 411

When doing a git push, I was getting the following error. error: RPC failed; result=22, HTTP code = 411 fatal: The remote end hung up unexpectedly This fixed it: git config http.postBuffer 524288000

Posted in git, Linux | Comments Off on git push error: RPC failed; result=22, HTTP code = 411