diff --git a/patches/systemvm/debian/buildsystemvm.sh b/patches/systemvm/debian/buildsystemvm.sh
index 10aedaa52f7..3223b90eebe 100755
--- a/patches/systemvm/debian/buildsystemvm.sh
+++ b/patches/systemvm/debian/buildsystemvm.sh
@@ -1,22 +1,15 @@
#!/bin/bash
-# Copyright (C) 2011 Citrix Systems, Inc. All rights reserved
-#
-# This software is licensed under the GNU General Public License v3 or later.
-#
-# It is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or any later version.
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see .
-#
-
-
+#Copyright 2012 Citrix Systems, Inc. Licensed under the
+#Apache License, Version 2.0 (the "License"); you may not use this
+#file except in compliance with the License. Citrix Systems, Inc.
+#reserves all rights not expressly granted by the License.
+#You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
+#Unless required by applicable law or agreed to in writing, software
+#distributed under the License is distributed on an "AS IS" BASIS,
+#WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+#See the License for the specific language governing permissions and
+#limitations under the License.
set -e
set -x
diff --git a/patches/systemvm/debian/config/root/redundant_router/primary-backup.sh.templ b/patches/systemvm/debian/config/root/redundant_router/primary-backup.sh.templ
index d6221d75926..f5e13ee6805 100644
--- a/patches/systemvm/debian/config/root/redundant_router/primary-backup.sh.templ
+++ b/patches/systemvm/debian/config/root/redundant_router/primary-backup.sh.templ
@@ -1,21 +1,13 @@
-#!/bin/sh
-#
-# (C) 2008 by Pablo Neira Ayuso
-#
-# This software may be used and distributed according to the terms
-# of the GNU General Public License, incorporated herein by reference.
-#
-# Description:
-#
-# This is the script for primary-backup setups for keepalived
-# (http://www.keepalived.org). You may adapt it to make it work with other
-# high-availability managers.
-#
-# Do not forget to include the required modifications to your keepalived.conf
-# file to invoke this script during keepalived's state transitions.
-#
-# Contributions to improve this script are welcome :).
-#
+#Copyright 2012 Citrix Systems, Inc. Licensed under the
+#Apache License, Version 2.0 (the "License"); you may not use this
+#file except in compliance with the License. Citrix Systems, Inc.
+#reserves all rights not expressly granted by the License.
+#You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
+#Unless required by applicable law or agreed to in writing, software
+#distributed under the License is distributed on an "AS IS" BASIS,
+#WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+#See the License for the specific language governing permissions and
+#limitations under the License.
CONNTRACKD_BIN=/usr/sbin/conntrackd
CONNTRACKD_LOCK=/var/lock/conntrack.lock
diff --git a/patches/systemvm/debian/xe/xe-daemon b/patches/systemvm/debian/xe/xe-daemon
index 9921e1b5290..d949895b2dd 100644
--- a/patches/systemvm/debian/xe/xe-daemon
+++ b/patches/systemvm/debian/xe/xe-daemon
@@ -1,20 +1,15 @@
#!/bin/bash
-# Copyright (C) 2009 Citrix Systems Inc.
-#
-# This program is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public License
-# as published by the Free Software Foundation; either version 2
-# of the License, or (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+#Copyright 2012 Citrix Systems, Inc. Licensed under the
+#Apache License, Version 2.0 (the "License"); you may not use this
+#file except in compliance with the License. Citrix Systems, Inc.
+#reserves all rights not expressly granted by the License.
+#You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
+#Unless required by applicable law or agreed to in writing, software
+#distributed under the License is distributed on an "AS IS" BASIS,
+#WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+#See the License for the specific language governing permissions and
+#limitations under the License.
LANG="C"
export LANG
diff --git a/patches/systemvm/debian/xe/xe-linux-distribution b/patches/systemvm/debian/xe/xe-linux-distribution
index 5034b4d0f7e..4a940dde455 100644
--- a/patches/systemvm/debian/xe/xe-linux-distribution
+++ b/patches/systemvm/debian/xe/xe-linux-distribution
@@ -1,20 +1,15 @@
#! /bin/sh
-# Copyright (C) 2009 Citrix Systems Inc.
-#
-# This program is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public License
-# as published by the Free Software Foundation; either version 2
-# of the License, or (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+#Copyright 2012 Citrix Systems, Inc. Licensed under the
+#Apache License, Version 2.0 (the "License"); you may not use this
+#file except in compliance with the License. Citrix Systems, Inc.
+#reserves all rights not expressly granted by the License.
+#You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
+#Unless required by applicable law or agreed to in writing, software
+#distributed under the License is distributed on an "AS IS" BASIS,
+#WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+#See the License for the specific language governing permissions and
+#limitations under the License.
# Script to write information about the current distribution to stdout or a file.
# Information collected:
diff --git a/patches/systemvm/debian/xe/xe-update-guest-attrs b/patches/systemvm/debian/xe/xe-update-guest-attrs
index ceee1ce8553..e00d9817950 100644
--- a/patches/systemvm/debian/xe/xe-update-guest-attrs
+++ b/patches/systemvm/debian/xe/xe-update-guest-attrs
@@ -1,20 +1,15 @@
#!/bin/sh
-# Copyright (C) 2009 Citrix Systems Inc.
-#
-# This program is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public License
-# as published by the Free Software Foundation; either version 2
-# of the License, or (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+#Copyright 2012 Citrix Systems, Inc. Licensed under the
+#Apache License, Version 2.0 (the "License"); you may not use this
+#file except in compliance with the License. Citrix Systems, Inc.
+#reserves all rights not expressly granted by the License.
+#You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
+#Unless required by applicable law or agreed to in writing, software
+#distributed under the License is distributed on an "AS IS" BASIS,
+#WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+#See the License for the specific language governing permissions and
+#limitations under the License.
# Script to write information about the guest to XenStore.
#
diff --git a/python/bindir/cloud-setup-baremetal b/python/bindir/cloud-setup-baremetal
index 2c95fcf1d11..6a4fbf7860d 100755
--- a/python/bindir/cloud-setup-baremetal
+++ b/python/bindir/cloud-setup-baremetal
@@ -1,21 +1,16 @@
#!/usr/bin/python
#
-# Copyright (C) 2010 Cloud.com, Inc. All rights reserved.
-#
-# This software is licensed under the GNU General Public License v3 or later.
-#
-# It is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or any later version.
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see .
-#
+#copyright 2012 Citrix Systems, Inc. Licensed under the
+#Apache License, Version 2.0 (the "License"); you may not use this
+#file except in compliance with the License. Citrix Systems, Inc.
+#reserves all rights not expressly granted by the License.
+#You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
+#Unless required by applicable law or agreed to in writing, software
+#distributed under the License is distributed on an "AS IS" BASIS,
+#WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+#See the License for the specific language governing permissions and
+#limitations under the License.
import sys, os
from subprocess import PIPE, Popen
diff --git a/scripts/vm/hypervisor/xenserver/xenserver60/qemu-dm-wrapper b/scripts/vm/hypervisor/xenserver/xenserver60/qemu-dm-wrapper
index 1ebdbaa46f1..9a0703d8360 100755
--- a/scripts/vm/hypervisor/xenserver/xenserver60/qemu-dm-wrapper
+++ b/scripts/vm/hypervisor/xenserver/xenserver60/qemu-dm-wrapper
@@ -1,17 +1,15 @@
#!/usr/bin/python
-#
-# Copyright (c) Citrix Systems 2007-2011
-# Author: Gianni Tedesco and Dave Scott
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License as published
-# by the Free Software Foundation; version 2.1 only. with the special
-# exception on linking described in file LICENSE.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License for more details.
+
+#Copyright 2012 Citrix Systems, Inc. Licensed under the
+#Apache License, Version 2.0 (the "License"); you may not use this
+#file except in compliance with the License. Citrix Systems, Inc.
+#reserves all rights not expressly granted by the License.
+#You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
+#Unless required by applicable law or agreed to in writing, software
+#distributed under the License is distributed on an "AS IS" BASIS,
+#WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+#See the License for the specific language governing permissions and
+#limitations under the License.
from xen.lowlevel import xs