Powershell "RunAs" causing recycle bin issues. Would like some input please.

I developed a script to assist our UserAdmins with creation of AD user accounts and create home folders on the server shares.  I am encountering an issue with the recycle bin becoming corrupt when the user first logs in.  This script must be run
with an elevated account with permissions to the shares.  I also noted a change in the way the recycle bin is displayed in the share.
The home folder is created using: 
New-Item -ItemType Directory -Force -Path $directory
If I log into my machine as my elevated account and run powershell/powershell_ise, all is well.  The recycle bin displays as "Recycle Bin" with the correct icon image
However, if I log into my machine with my non-elevated account and select "Run as a different user" for Powershell or Powershell_ISE and use my same elevated account from above the users receive "corrupt" recycle bin errors when logging
in or viewing the recycle bin properties.  Additionally, recycle bin is now listed as "$Recyle.Bin" and is using a folder icon.  This issue is resolved by removing the users AD account from the home folder permissions and re-adding it with
identical permissions.
I see this behavior using Win8.1 x64 as well as Win7 x64 Enterprise.
On another somewhat relevant topic, when launching Powershell_ISE with "Run as a different user" it often freezes and must be forcibly closed.  Could be relevant, could be coincidence.
I appreciate any input you may have regarding this issue.
Thanks,
Jeff

I'm trying not to come off as combative, but I feel you are misunderstanding or I am not being clear. The recycle bin is auto-created when the user first logs into the machine as is are the sub folders to the parent folder.  All of the desktop.ini files,
recycle bin folders and various other user profile objects are created upon first login by that user inside of the folder created in the PowerShell script.  Prior to this the user admins were manually creating the same parent folder with their elevated
accounts.  Given the isolated conditions in which it works vs when it doesn't there is no indication that permissions are causing this issue.
I'll try to explain why the issue, I believe, lies with PowerShell.
1) Launch a PowerShell session from the current logged in elevated account
2) Run the script
3) Users home folder is created
4) Upon user logging in for the first time the user profile objects are created in the home folder on the share
5) No issues with recycle bin
vs - from the same machine, same script
1) Launch a PowerShell session with "Run as different user" context using the same account from above
2) Run the script
3) users home folder is created
4) Upon user logging in for the first time the user profile objects are created in the home folder on the share
5) Recycle bin is corrupt and icon is wrong
The only thing that changes between these 2 scenarios is the way in which PowerShell is run.
It's the same computer, the same test user account, the same share, same GPOs and AppSense policies.
Scenario 1 is run from elevated account logged into local machine
Scenario 2 is run from non-elevated account with "Run as different user" context using the elevated account
I know I'm sounding like a broken record but it doesn't make sense AppSense or GPO or even folder permission would cause an issue when the folder is being created using the same account in both situations.

Similar Messages

  • Maybe making the switch from AVID to FCP, would like some input please.

    Happy T-Day to all. Would really appreciate any thoughts on this. I have many questions and need some answers from folks who are not always pushing AVID ( my vendor) I am a one man shop and use all Apple apps (LiveType, Motion, etc.) but have always stayed in my comfort zone with AVID Xpro and MOJO. Am thinking of going to Media Composer but after a few days of consideration and a trip to an Apple store, I may do a complete turn around and commot to FCP. Recently made the move to HD with the Sony XDCAM HD system. Here are my questions...plese be patient, this is a major move for me.
    1. If I purchase a new Intel G-5, will the internal SATA drives be OK for 35MPS HD?
    2. What AJA card or product should I buy so I can view HD SDI on a client monitor and output HD to a Sony XDCAM HD F-70 Deck?
    3. What graphics card should I order on the new machine?
    4. Can I use the FAM ( File Access Mode) to tranfer content?
    5. Any other considerations when ordering the new Intel machine?
    I know I have many questions, but I really believe it is time for me to make the move. Any help would be really appreciated. Thanks again.
    Tdub

    1. Yes, but just. You'd only get 1 stream. Faster drives would allow you to do more than one layer of real time playback. You could stripe more than one internal sata and get the job done that way.
    2. Kona LHe will do this, however you'd gain the ability to upconvert and cross convert the video to just about any format with the Kona 3.
    3.The X1900. Motion and some effects in FCP will take advantage of it... down the line FCP is likely to rely more on the GPU is an educated guess of mine. the top of the line card is faster, but not enough to substaniate the price if you're working in Video. If you were working in 3D CAD environments, then the top of the liner would be the best choice.
    4.I don't use XDCAM here, so I'm presuming that you're talking about a transfer mode with that. I'm pretty sure FCP 5.1.2 added this capability. Might search the COW on this term in the FCP forum there. http://www.creativecow..net.
    5.Working with HD and MPEG streams would leave me wanting the fastest of the three machines. You'll want 4 gigs of RAM, but it's less expensive from other than Apple. I know just how scary it can be to move to a new platform, and did exactly as you are contemplating when FCP 2 arrived. I've never looked back. Hang here once you get started, and we'll help you with the transition. There is a book out there in the pro training series from Apple/Peachpit on ediiting on FCP if you're coming from Avid. I'd recommend you get that book. Will ease the transition no doubt.
    Hope you make the jump!
    Jerry

  • Hi everyone I have a macbook pro mid 2010 17'' 2.66 i7 looking to put a new hard drive in it something like a 250 gb  ,  orig drive 500 gb 5400 toshiba but i don;t really need that much space so i would like some input, type,speed,brand,compatibly,noise

    I have a macbook pro mid 2010 17'' 2.66 i7 looking to put a new hard drive in it something like a 250 gb  ,  orig drive 500 gb 5400 toshiba but i don;t really need that much space so i would like some input, type,speed,brand,compatibly,noise Thank You!!

    There's no reason to install a smaller hard drive. In some cases, it may decrease performance.
    Your MacBook Pro comes with a 5400 rpm hard drive, so what you can do is to install a smaller, 7200 rpm hard drive, so you will get a better performance. Any 2'5" SATA hard drive will work, but you can have a look at OWC for hard drives > http://eshop.macsales.com/shop/hard-drives/2.5-Notebook/
    HGST and Seagate hard drives have a good reputation, so you can purchase one of them

  • I bought an album on iTunes and 3 of the songs only play for 30 seconds. I have tried re-downloading the album 3 times and the problem has not been fixed. I would like some help please and thank you.

    I bought an album on iTunes and 3 of the songs only play for 30 seconds. I have tried re-downloading the album 3 times and the problem has not been fixed. I would like some help please and thank you.
    Artist: Imagine Dragons
    Album: Night Vision

    Report it here:
    iTunes Store Support
    http://www.apple.com/emea/support/itunes/contact.html

  • Itunes library issue, would like some insight

    hopefully someone can help me out with this, located on my laptops hard drive, in my itunes music folder, i have 50gb of music. All of it is on my ipod organized and everything, i am very pleased. however i would like to get it off my harddrive as it is taking up much needed space. I have a backup usb 150gb drive. my question is, if i take all the albums out of my music folder and put them on the removable hard drive, will that affect my ipod at all? and if it wont affect it what is the best way to go about it? i think all it will do is not allow me to edit the music that is currently on my ipod, but not sure. please help out, thanks

    Yes, read that article. It's good.
    If you just move the files using Windows Explorer, iTunes will not be able to find them. You need to use the itunes Consolidate library command to move the files.
    One thing the article doesn't mention, you should assign a permanent drive letter to the exHD.
    That way, no matter what you plug into your USB ports, it will always stay the same within Windows, and itunes won't lose the path to your music files.
    My advice is to give it something fairly far down in the alphabet, like M: for music.
    http://support.microsoft.com/kb/307844

  • Would like some input on models please.

    I have been Mac user for years and want to get an Ipad but like most money is tight, Have a friend that has a brand new 64gig IPad 1 in box never used. Only want one to use when travial for email, online banking, a little surfing and a few movies and games. Dont need a camara. My friend wants $300 for it. I cant see 1 specs in Apple Store. Can some one please give me some pro and con input on this please.

    The specs are in the Apple Store: look harder.
    As long as your friend"s iPod satisfies your requirements regarding WiFi only versus 3G connection, bite his/her arm off. You can see the prices as well as anybody else in the Apple Store.

  • Ordering new Mac Pro. Would like some advise please.

    Okay, here we go. I am a freelancer who shoots in 1080i and 720p using a JVC 700 U camera with really good glass. in a small market. So bringing the media in is a piece of cake. I do not see me going to 2K or 4k anytime soon. I produce a weekly hour long sports program and various other projects... training, docs, marketing videos, etc. Very seldom more than 4 streams on the timeline. I have a budget of around $5,000 for a new machine. Here is what I am leaning towards. I would appreciate any advice.
    6 core, 32 GB ram, upgrade to D700 GPU's, 512 GB storage. I use two G-Tech 4TB Thunderbolt drives for media. I also have a Thunderbolt display. Any concerns or thoughts? You folks always have great advice so I am looking forward to your opinions.
    Cheers,
    Tom

    quote:
    Basically the FirePro D300 is a lesser version of the W7000, the D500 is a lesser version of the W8000 and the D700 a lesser version of the W9000. Interestingly the D700 (Practically a Rebrand) has not been physically disabled any further than the W9000 yet it gives about 0.5 TeraFlops less compute than the AMD FirePro W9000. Needless to say AMD’s take on efficiency is very interesting and though we dont see a market for such a series apart from Mac Pros, AMD might decide otherwise.
    http://wccftech.com/generation-amd-professional-gpu-arrives-firepro-d700-leads-p ack-35-teraflops-compute/

  • Scam- would like some input ;-))

    My friend is visiting from Europe. She has a Mac Book Air. Yesterday she got this pop up: Security warning, call tech support. I called on her behalf. Mr. India suggested our household is compromised by hackers from Russia. Ok, I am not ted  savvy and I am not feeling well. I gave him her name, email address and year of birth. He wanted a payment of $299.99 to www.althim.com and got very pushy. Too pushy. I quit it right there and ended the phone call.
    Then I found out about this scam. My friend is super nervous and doesn't know what this guy is able to do with her data.
    Is anyone out there to give us advice. What on earth can she do? What damage can Andy 1-800-870-2451 do?
    It is visible that he is fiddling with her data and I wish I could call the FBI...they wouldn't be interested. Anyways, any good advice is much appreciated. Thank you!

    She would have had to give "Andy" expressed permission to do anything with her computer, so I don't think she should have any concerns about that. After you paid the $299, he would probably have asked her to do some things so he could first identify her computer address and then she would have had to open up sharing permissions and perhaps even install some software before he could compromise the computer. Anything would be possible at that point.
    It's unfortunate that he obtained a small amount of privacy information about her, but I suspect the worst that could happen would be an increase in the amount of spam and phishing attempts she would receive via e-mail. Caution her not to open any attachments or click any links in an e-mail from someone she doesn't know.
    And just so you know, there is no way for a web site to scan any computer for problems, security or otherwise, so always ignore any such warnings.

  • Zone edit, my first attempt; would like some assitance please :P

    Hello,
    spent the week getting this server up (first time). have done well, got to domains working just fine.
    but i'd like to be able to add an SPF record to my zone. but i have not idea how to do this. From what i can tell from reading the forums and such; this is my zone record to edit (correct?):
    zone "ipaultech.com." in {
    file "ipaultech.com.zone";
    type master;
    if this true, how do i add the following text record:
    "v=spf1 a mx ~all"
    if you could "dumb-down" your ansewer/reply i'd greatly appreciated it
    --Paul
    BTW: if you know any links for Macosx and dns/bind, i wouldn't mind them.

    Ahhhhh..... i totally get this. man i wish i knew about this dir about three days ago
    much thanks to you ((¿))
    --Paul
    • G5 Tower >> • Two- 15" G4 Pb >> • 20" G5 iMac >> • Mini (cute little server)

  • I would like some Help please!

    Hey everyone. I bought a new Ipod 30Gb Black Video yesterday which i recieved at about 11am. I turned it on and it got stalled on hold. I couldnt turn the ipod off or nothing at around 3 the Ipod was dead so I installed all the programs and plugged it into the computer at around 3.45. It has been on all night and now at almost 1 the next day it is still saying Do Not Disconnect. I have been into Itunes many times and cannot see that in anyway being in contact with the ipod. What should I do. I am planning to leave it on till about 7.30 tonight but thats the latest I can really do.
    Also When I open up itunes and go into Prefrences and click Ipod it says that there is no Ipod Connected.

    Report it here:
    iTunes Store Support
    http://www.apple.com/emea/support/itunes/contact.html

  • I am having bugs and would like user input about the keyboard

    i would like some input from other users and if you are having an trouble typing on the keyboard.
    freezes or anything else. resets or bugs.
    <Edited by Host>

    ok it just did it again so it is definitely not emoji.
    i am trying to pay attention to exactly what happens and when it does what key i am pushing.
    i just happened twice and the first time was on the letter "o" and the second time on the letter "i". i have tried to fat finger the return and send and back buttons to see if that had something to do with it and nothing. if you fat finger send well it sends the text lol. i even intentionally touched in the texting space right above the letter i and o too see if i am touching the text space and causing it. it does nothing. it seems to happen when i am typing really fast. very annoying... this never happened on my 3g or any of my 4 3GS phones...
    i guess i will do a full restore tonight and see if that ends the problem. i will not put emoji back on for a while to be sure it is not that program.
    if anyone else has experienced this then hit me up on here and let me know. i am not sure about this new phone but on my last one the keyboard would start to freeze up and pretty much stop typing if i went for to many days without turning the phone off and restarting it. restart seems to fix it.
    edit ~ ya its doing it bad now... did it on letter "y" this time.... seems to happen on the top row of keys. i just restored this phone from previous phones backup so i will wipe it and do a full install. hopefully that fixes it. maybe the OS got corrupted somehow.

  • To whom it may concern, Since I have downloaded the Firefox update for my phone. I have not been able to copy and paste. I would like some info on this. Thanks

    With the previous version of Firefox for my mobile phone it had the gingerbread copy and paste system and now I am not able to do so at this point. I just want to know how to copy and paste with the new update version of Firefox for my mobile phone. I have a Samsung Infuse. I would like some input on this. Thank you and much appreciated.

    Sorry, the new user interface in the latest update did not have selection/copying of text ready in time for its release. We're working on adding it back for an upcoming version very soon. If you'd like, you can already start testing it in our [https://wiki.mozilla.org/Mobile/Platforms/Android#Download_Nightly nightly development builds].

  • PowerShell - to search recycle bin - for any document with title containing "disaster" in it?

    Hi there,
    I am looking for PowerShell - to search recycle bin - for any document with title containing "disaster" in it? 
    E.g. it should search for any documents with title "SharePoint Disaster Recover.doc" or whatever title contains this word?
    Thank you so much.

    This should do it:
    Get-SPSite http://yourServer/sites/yourSite |
    Select -ExpandProperty RecycleBin |
    Where { $_.Title -Like "*disaster*" } |
    Select DirName, Title
    or for all Site Collections in the farm:
    Get-SPSite -Limit All |
    Select -ExpandProperty RecycleBin |
    Where { $_.Title -Like "*disaster*" } |
    Select DirName, Title
    Mike Smith TechTrainingNotes.blogspot.com
    Books:
    SharePoint 2007 2010 Customization for the Site Owner,
    SharePoint 2010 Security for the Site Owner

  • Can anyone offer some advice i am looking to upgrade the OS system on one of my macbook pro's, currently running os10.4.11, I would like to upgrade to OS10.5? how would I go about this, and is there a cost, for what is an old operating system now?

    Can anyone offer some advice i am looking to upgrade the OS system on one of my macbook pro's, currently running os10.4.11, I would like to upgrade to OS10.5? how would I go about this, and is there a cost, for what is an old operating system now?

    Since your Mac probably came with 10.4, there is no longer a way to get 10.5 Leopard install media. IF it has the requirements, you may be able to upgrade to 10.6 Snow Leopard by buying the boxed install media at the Apple Store for $30.
    System requirements are found here: http://support.apple.com/kb/SP575
    General support can be found here: http://www.apple.com/support/snowleopard/

  • HT3986 I have a pc that is one year old and the hard drive is crashing we use it only for quick books to run our small business I would like to buy amac and install the OS  forom the pc to the apple product i will not use the pc after can i use the OS off

    I have a pc that is one year old and the hard drive is crashing we use it only for quick books to run our small business I would like to buy a macmini and install the OS  from the pc to the apple product i will not use the pc after, can i use the OS off the pc or do I have to purchase another?

    I think you can get Windows 7 for around $99. Install the 64bit version as the 32bit version will not be able to use all your new computer's ram if you have more than about 3.5gb.
    Back up your quick books data now before the old hard drive dies. You can copy your data over to your new installation of Windows and quick books.
    By the way, there is quick books for Mac http://quickbooks.intuit.com/mac/?sc=BNR-000-COR-quickbooks&priorityCode=4902000 000&cid=ppc_google_QB-Intuit-Core-Brand-Mac_quick-books-for-mac_exact&site=&ad_i d=9347918288&raw_keyword=quick%20books%20for%20mac
    So you may not need to install Windows at all.

Maybe you are looking for

  • Cant Save or Share photo (Note 3 PS Touch)

    Hi guys, Please help me on this problem. After I done with my picture i want to share or save the image to gallery, after i press the bottom third icon there are 3 selection for me to choose 1.Upload to Creative Cloud 2.Save to Gallery 3.Share.... Af

  • Cannot open pdf in IE browser

    Adobe Reader 11.0.5. Danish, WINXP SP3, IE8. I can open PDF from PC but not from browser only when right click on file and then save on PC. This works in some cases. Problem arised I believe after updating 11.0.5. I have checked PDF enabled under Add

  • Imovie will not render photos with ken burns effect

    I have started to produce a video and have tried to import photos from both iphotos and straight from desktop however when i do this the red bar showing the state of rendering does not move. The photo will not render and therfor i am unable to use th

  • Coulmn heading in several rows using 'Delimited' option

    Hello folks -- I am using Oracle Reports 6i and when generating a File to 'Delimited' to produce a Text file, I am getting the Column headings repeated in every row. So, all the columns are being produced in every row and every column and then data i

  • Noises While Listening AIFF Files In Cd Spin Doctor

    Hello everybody: I`m using Toast 9.0.4 in a Mac Mini Intel Core Duo 1.66 Ghz. 2 Gb Ram. Mac OS 10.4.11 Everytime I capture audio with CD Spin Doctor everything goes fine but when I begin to listen it appears noises and interruptions. The funny thing