Install on Vista or 7

Here you can post about non-standard installation methods
(for example when using grub4dos).
User avatar
agreimann
Samurai
Samurai
Posts: 137
Joined: 19 Apr 2011, 21:09
Location: U.S.

Install on Vista or 7

Post#1 by agreimann » 20 Apr 2011, 04:30

I noticed that Porteus did not allow installation to USB in Vista and 7, unless UAC is disabled, which while it is convenient to do so, it is recommended leave it ON. If you do try to run bootinst.bat as a user, certain commands cannot complete, because you are not an administrator, and if you try to "Run as administrator" it will detect C: as the installation drive! This is where this script comes in.

There is a way, however, to get it to install, by using these steps.

1) Open Computer and note the drive letter of the flash drive you want to install to. For this how-to, let's say it is drive E:. (This step presumes you have already copied the boot and porteus folders.)
2) Open the Start menu and type cmd.
3) Right-click cmd, click "Run as administrator", type in your password if required, then click Yes or OK.
4) Type your drive letter to switch. In this case, I'd type E: and then press enter.
5) Type cd boot then press enter.
6) Type .\bootinst.bat
7) Read the conditions and press enter. You should now have Porteus on a bootable flash drive. :Yahoo!:

(**NOTE TO PORTEUS MAINTAINERS:** Most market share is transitioning to Windows 7 from Windows XP; a similar guide, or this one, should be included in the next Porteus release, so new Porteus users can install Porteus to a flash drive.)

User avatar
Hamza
Warlord
Warlord
Posts: 1908
Joined: 28 Dec 2010, 07:41
Distribution: Porteus
Location: France

Re: Install on Vista or 7

Post#2 by Hamza » 20 Apr 2011, 08:17

Moved from HOWTO & Ressources to Installation methods

Reason : It is about howto install Porteus on Windows.
NjVFQzY2Rg==

User avatar
Ahau
King of Docs
King of Docs
Posts: 1331
Joined: 28 Dec 2010, 15:18
Distribution: LXDE & Xfce 32/64-bit
Location: USA

Re: Install on Vista or 7

Post#3 by Ahau » 20 Apr 2011, 14:49

welcome, agreimann!

Thanks for the howto!

Version 1.0 is in development and will ship with new installation scripts-- lin_start_here.sh and win_start_here.hta. Both scripts link to an install guide and other documentation, and then setup the flashdrive for booting. If you have time and you're willing, please try the installers for the 32-bit beta and 64-bit RC1 versions (available from the testing areas of our server) -- I'm sure the maintainers would like to have more testing on windows installation. If you have suggestions to make on the install guide, to help make it more clear for windows users (Vista and 7 especially), please let me know, and I'll make some modifications to the guide. I'm still using XP, so haven't been able to test them on newer windows versions.

Thanks!!
Please take a look at our online documentation, here. Suggestions are welcome!

User avatar
agreimann
Samurai
Samurai
Posts: 137
Joined: 19 Apr 2011, 21:09
Location: U.S.

Re: Install on Vista or 7

Post#4 by agreimann » 20 Apr 2011, 18:34

Thank you for the welcome!

On Windows, I can program with Windows Script Host and Windows HTAs. If you need help getting this up fast, let me know. I may be a new poster, but I'm definitely not new to programming, or at computing in general, especially Linux :wink: (though in there it's C, bash, and dialog scripts within bash).

I posted a link to this thread in the Installation as well. You'll notice the link to the post that used to be where I posted it. I'll see if I can update that, then.

User avatar
Hamza
Warlord
Warlord
Posts: 1908
Joined: 28 Dec 2010, 07:41
Distribution: Porteus
Location: France

Re: Install on Vista or 7

Post#5 by Hamza » 21 Apr 2011, 12:06

Most market share is transitioning to Windows 7 from Windows XP; a similar guide, or this one, should be included in the next Porteus release, so new Porteus users can install Porteus to a flash drive.
We need The DOC Team ! Ahau and Captain_picard are here!

Posted after 14 hours 16 minutes 24 seconds:
If you want an example , you can unetbootin , this is good example.

Is this possible to insert a function for see the last version available?

Regards,
NjVFQzY2Rg==

User avatar
Blaze
DEV Team
DEV Team
Posts: 3860
Joined: 28 Dec 2010, 11:31
Distribution: ⟰ Porteus current ☯ all DEs ☯
Location: ☭ Russian Federation, Lipetsk region, Dankov
Contact:

Re: Install on Vista or 7

Post#6 by Blaze » 21 Apr 2011, 12:34

Hello everybody.

I wrote and compiled a program Porteus-to-a-flash-drive.exe using AutoIt v3.

Update.

Description

This program can:
  • Disable User Account Control (UAC) on Win 7 or Vista
  • Run win32 "cmd" and help menu with "How to install Porteus to a Flash Drive"
Source code of this program for AutoIt:

Code: Select all

#NoTrayIcon
#RequireAdmin
Opt("TrayIconHide", 1)
$a = "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System"
$b = "ConsentPromptBehaviorAdmin"
$c = "REG_DWORD"
$d = "0"
$e = "PromptOnSecureDesktop"
$f = "EnableLUA"
$var1 = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System", "ConsentPromptBehaviorAdmin")
$var2 = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System", "PromptOnSecureDesktop")
$var3 = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System", "EnableLUA")
$response = MsgBox(4, "Warning", 'This program will temporarily disable UAC. This may put your computer at risk.' & @CR & 'When the program finishes running, you will need to type “uac” in the Start menu, click "Change User Account Control Settings" and restart.' & @CR & 'Are you sure you want to continue?')
If $response = 6 then
If $var1 = 5 Then
	FileWrite (@CommonFilesDir & "\System\en-US\mui\log.txt","Text")
	RegWrite($a, $b, $c, $d)
EndIf
If $var2 = 1 Then
	FileWrite (@CommonFilesDir & "\System\en-US\mui\log.txt","Text")
	RegWrite($a, $e, $c, $d)
EndIf
If $var1 = 2 Then
	FileWrite (@CommonFilesDir & "\System\en-US\mui\log.txt","Text")
	RegWrite($a, $b, $c, $d)
EndIf
If $var3 = 1 Then
	FileWrite (@CommonFilesDir & "\System\en-US\mui\log.txt","Text")
	RegWrite($a, $f, $c, $d)
EndIf
Run( @WindowsDir & "\system32\cmd.exe" )
MsgBox(262144, "How to install Porteus on your USB Flash drive", '1) Type your drive letter of USB Flash (for examle E:) and then presss “Enter”' & @CR & '2) Type “cd boot\scripts” then press “Enter”' & @CR & '3) Type “.\bootinst.bat”')
Else
	Exit
EndIf
Last edited by Blaze on 22 Apr 2011, 07:11, edited 1 time in total.
Linux 6.6.11-porteus #1 SMP PREEMPT_DYNAMIC Sun Jan 14 12:07:37 MSK 2024 x86_64 Intel(R) Xeon(R) CPU E3-1270 v6 @ 3.80GHz GenuineIntel GNU/Linux
MS-7A12 » [AMD/ATI] Navi 23 [Radeon RX 6600] [1002:73ff] (rev c7) » Vengeance LPX 16GB DDR4 K2 3200MHz C16

User avatar
Hamza
Warlord
Warlord
Posts: 1908
Joined: 28 Dec 2010, 07:41
Distribution: Porteus
Location: France

Re: Install on Vista or 7

Post#7 by Hamza » 21 Apr 2011, 12:38

@Blaze

This is very useful ! Thanks!
NjVFQzY2Rg==

User avatar
agreimann
Samurai
Samurai
Posts: 137
Joined: 19 Apr 2011, 21:09
Location: U.S.

Re: Install on Vista or 7

Post#8 by agreimann » 21 Apr 2011, 16:51

@Blaze: This is honestly great... *but* we need to do things the **right** way. We can't just hack our way into the system for one installer to run by turning off User Account Control. That will leave the computer at risk, and if nothing else, if an experienced Windows client ran this program and saw it started to dismantle UAC, he'd kill it, and probably not run it again, suspecting it is malware. Always use the guidelines for Windows, and for the new UI Windows Aero, when programming--especially if you want OSS to be respected in the proprietary software sphere.

Here's what I'd recommend if you want to build this kind of installer. You could warn the user "This program will temporarily disable UAC. This may put your computer at risk. When the program finishes running, you will need to type uac in the Start menu, click "Change User Account Control Settings" and restart." However... I think it still should ask for permissions instead. Also, completely disabling UAC and having it take full effect requires a system reboot on Windows 7.

I'm sorry for criticizing the script this hard; please take this as being constructive... if nothing else. :) Also, I did read through the code really fast... if you did call for UAC to ask, and I didn't see it, I apologize.

User avatar
Hamza
Warlord
Warlord
Posts: 1908
Joined: 28 Dec 2010, 07:41
Distribution: Porteus
Location: France

Re: Install on Vista or 7

Post#9 by Hamza » 21 Apr 2011, 16:57

You could warn the user "This program will temporarily disable UAC. This may put your computer at risk. When the program finishes running, you will need to type uac in the Start menu, click "Change User Account Control Settings" and restart."
I agree with you , and maybe the user can decide if he want disable UAC.
NjVFQzY2Rg==

User avatar
fanthom
Moderator Team
Moderator Team
Posts: 5660
Joined: 28 Dec 2010, 02:42
Distribution: Porteus Kiosk
Location: Poland
Contact:

Re: Install on Vista or 7

Post#10 by fanthom » 21 Apr 2011, 21:04

things are getting very interesting here - we have 2 (or even 3) installers now :)
I hope there will be some consensus before FINAL.

Great job guys!
Please add [Solved] to your thread title if the solution was found.

User avatar
Hamza
Warlord
Warlord
Posts: 1908
Joined: 28 Dec 2010, 07:41
Distribution: Porteus
Location: France

Re: Install on Vista or 7

Post#11 by Hamza » 21 Apr 2011, 21:06

I writing a tool for upgrade from older version to latest. It can be an installer of latest version.
NjVFQzY2Rg==

User avatar
Blaze
DEV Team
DEV Team
Posts: 3860
Joined: 28 Dec 2010, 11:31
Distribution: ⟰ Porteus current ☯ all DEs ☯
Location: ☭ Russian Federation, Lipetsk region, Dankov
Contact:

Re: Install on Vista or 7

Post#12 by Blaze » 22 Apr 2011, 07:15

agreimann, ok, so I updated my program.
Look at my 1-st post of this topic.
Thanks.

P.S. I don't use UAC because is evil with stupid questions :D
Better use a good antivirus.
Linux 6.6.11-porteus #1 SMP PREEMPT_DYNAMIC Sun Jan 14 12:07:37 MSK 2024 x86_64 Intel(R) Xeon(R) CPU E3-1270 v6 @ 3.80GHz GenuineIntel GNU/Linux
MS-7A12 » [AMD/ATI] Navi 23 [Radeon RX 6600] [1002:73ff] (rev c7) » Vengeance LPX 16GB DDR4 K2 3200MHz C16

User avatar
Hamza
Warlord
Warlord
Posts: 1908
Joined: 28 Dec 2010, 07:41
Distribution: Porteus
Location: France

Re: Install on Vista or 7

Post#13 by Hamza » 22 Apr 2011, 09:10

If you want add UAC function , please add a message to GUI when it will disable UAC.
NjVFQzY2Rg==

User avatar
Blaze
DEV Team
DEV Team
Posts: 3860
Joined: 28 Dec 2010, 11:31
Distribution: ⟰ Porteus current ☯ all DEs ☯
Location: ☭ Russian Federation, Lipetsk region, Dankov
Contact:

Re: Install on Vista or 7

Post#14 by Blaze » 22 Apr 2011, 12:11

If you press
Image
Yes - This will disable UAC and run cmd with help menu
No - Exit
Linux 6.6.11-porteus #1 SMP PREEMPT_DYNAMIC Sun Jan 14 12:07:37 MSK 2024 x86_64 Intel(R) Xeon(R) CPU E3-1270 v6 @ 3.80GHz GenuineIntel GNU/Linux
MS-7A12 » [AMD/ATI] Navi 23 [Radeon RX 6600] [1002:73ff] (rev c7) » Vengeance LPX 16GB DDR4 K2 3200MHz C16

User avatar
Hamza
Warlord
Warlord
Posts: 1908
Joined: 28 Dec 2010, 07:41
Distribution: Porteus
Location: France

Re: Install on Vista or 7

Post#15 by Hamza » 22 Apr 2011, 12:15

@Blaze
That's perfect !

Just one thing, the buttons will be in Russian? Or maybe , it is the native language of your current OS?
NjVFQzY2Rg==

Post Reply