As pointed out by Alex in a comment,
arcpy.env.packageWorkspace
is an expected update in your script if you look at where the GP Service is deployed. The packageWorkspace is the directory itself. When publishing a service that uses SDE data, and you've referenced the SDE database in your datastore, a copy of the connection file (.sde) gets moved into the directory and your script is updated to reference that. This is expected and how its supposed to work.
You're right about "generally" speaking per your link different versions will work together:
According to this link I should however be able to publish form 10.2.2 to 10.1 without too many problems.
I do want to point out times though this wont be true. There have been a few tools which have been enhanced between 10.1 and 10.2.2. These tools can only be publish when each product is at the same version. (this is just a general note, this point wont be your issue).
There have also been some bugs fixed between the versions, mostly related to script update and data paths. Again, generally speaking most should work, but there could be cases that they dont. I dont have enough information about your workflow to say that updating Server to 10.2.2 will solve the problem (so I'm not suggesting that).
Your best test is with ArcMap, to navigate down into the v101 folder and find the .RLT (result) file. Drag that into your map. Open the Results window and under the "shared" node, run that. Thats basically like running the service, but running it locally, not via ArcGIS Server. If that works, its Server having problems connecting to SDE. If it doesn't work, its not resolving the path to your SDE connection file and I'd sort of expect the version differences perhaps messing something up. The easy "test" to prove that would be to hack the script in that directory to point to the connection file explicitly.
So,
georeferencing panel in ArcMap provides 2 options - update georeferencing and rectify.
Update georeferencing creates jgwx, pnwx, tfwx extensions and this can't be opened in GeoServer. A solution is to rectify all images, which creates pgw-like extensions.
To define a world file's projection in GeoServer you have to make an exact copy of projection definition from layer setup to new file with "SameNameAsLayer.prj" name and extension.
Best Answer
I had the same problem "Error – Failed to save raster dataset". For me, turns out the issue was that I was saving onto a drive whose free space was less than the amount of space required to store the new georeferenced image. Changing the directory the TIF was saved in resolved my problem.